[{"data":1,"prerenderedAt":359},["ShallowReactive",2],{"project-46454369":3},{"id":4,"name":5,"line":6,"line_source":7,"title":8,"url":9,"domain":10,"maker":11,"posted_at":12,"year":13,"points":14,"comments":15,"rank_in_year":16,"shown_in_year":17,"top":18,"tier":19,"category":20,"subcategory":21,"format":22,"keywords":23,"reception":29,"sentiment":30,"stance_mix":31,"scored_comments":36,"aspects":37,"strip":46,"post_text":48,"what":49,"said":78,"maker_in_thread":168,"shape":179,"grid":184,"attempts":320,"same_week":321,"maker_shows":350,"maker_hidden":351,"reader_version":352,"card":353},"46454369","git-prime","48-digit prime numbers every git commit","title","Show HN: 48-digit prime numbers every git commit","https:\u002F\u002Ftextonly.github.io\u002Fgit-prime\u002F","textonly.github.io","keepamovin",1767277572,2026,67,54,981,4366,23,"notable","dev_tools","git tooling","cli",[24,25,26,27,28],"git commit hash","prime numbers","miller-rabin","git vanity hash","sha-1","curious",-0.096,{"positive":32,"neutral":33,"mixed":34,"critical":35},2,16,1,6,25,{"design":38,"docs":40,"idea":41,"execution":42,"performance":43,"privacy":45},{"positive":39,"critical":34},0,{"positive":39,"critical":39},{"positive":32,"critical":39},{"positive":39,"critical":34},{"positive":39,"critical":44},3,{"positive":39,"critical":34},[44,39,44,39,44,44,39,39,44,39,34,39,44,39,44,39,34,44,39,44,39,47,44,39,39,44,44,39,47,39,34,34,39,44,44,44,34,39,39,39],5,null,{"problem":50,"audience":48,"pricing":48,"motivation":57,"time_to_build":48,"stack":61,"openness":75,"stage":76,"team_size":77},{"value":51,"source":52,"evidence":53},"Makes every git commit hash a certified 160-bit prime, for fun.","maker",[54],{"id":55,"by":11,"text":56},"46454506","Why? Fun. Now every commit is a certified 160-bit prime number. - Miller-Rabin primality test (40 rounds, ~10^-24 false positive rate) - Fuzzes commit messages with nonces until…",{"value":58,"source":52,"evidence":59},"Fun; the maker wants to use idle compute on pointless number theory.",[60],{"id":55,"by":11,"text":56},[62,70],{"value":63,"source":64,"evidence":65},"Python","commenter",[66],{"id":67,"by":68,"text":69},"46521098","tntxtnt","From doing MR rounds in pure Python: https:\u002F\u002Fgithub.com\u002Ftextonly\u002Fgit-prime\u002Fblob\u002Fmain\u002Fgit-prime-commit. Should be under 5 seconds in C or C++ using gmp",{"value":71,"source":72,"evidence":73},"Bash","inferred",[74],{"id":55,"by":11,"text":56},"open_source","launched","unknown",{"praise":79,"objections":90,"requests":117,"questions":133,"alternatives":147},[80],{"value":81,"source":64,"evidence":82},"Clever proof-of-work-style idea and fun math",[83,87],{"id":84,"by":85,"text":86},"46520556","haute_cuisine","This is amazing. A true proof of work. Have you considered finding hashes with leading zeros or making sure each hash starts with 1337?",{"id":88,"by":11,"text":89},"46521931","Thank you. This is the hn I’m here for. Probabilistic tests for definite primes still being so slimmest definitive is amazing to me. What structure are they approximating?",[91,98,106],{"value":92,"source":64,"evidence":93},"Install via curl piped to bash is risky",[94],{"id":95,"by":96,"text":97},"46521061","irishcoffee","Sure hope the first line of that bash script isn’t rm -rf $HOME\u002F* Please don’t ever suggest to anyone ever to curl a script and pipe it to bash. I’m sure this one is fine (I…",{"value":99,"source":64,"evidence":100},"Slow runtime; overhead from repeated git subprocess calls",[101,105],{"id":102,"by":103,"text":104},"46524954","Retr0id","No, MR in pure python is ~instantaneous for numbers of this magnitude. From looking at the code, the overhead will be from repeatedly invoking git as a subprocess.",{"id":67,"by":68,"text":69},{"value":107,"source":64,"evidence":108},"Primality test choice and false positive bound",[109,113],{"id":110,"by":111,"text":112},"46520013","tzs","> Miller-Rabin primality test (40 rounds, ~10^-24 false positive rate) It's way better than that. You are using the simplest upper bound for the false positive rate, which is…",{"id":114,"by":115,"text":116},"46527862","primemegently","For those that want more details on this fun rabbit hole of math, see the theory of Strong Pseudoprimes: https:\u002F\u002Fen.wikipedia.org\u002Fwiki\u002FStrong_pseudoprime Miller-Rabin in…",[118,129],{"value":119,"source":64,"evidence":120},"Store nonce as a git trailer, not in message body",[121,125],{"id":122,"by":123,"text":124},"46519865","hoten","Personally I'd append the Nonce as a git trailer, not to the message body. And would keep the date constant rather than use the time of each attempt (such that the only thing…",{"id":126,"by":127,"text":128},"46521347","kazinator","> Hash as int Should be \"Hash as decimal\". The hexadecimal hash is already the same integer. > Message: \"Fix critical bug\" + git-prime Nonce: 167 In the actual code it looks…",{"value":130,"source":64,"evidence":131},"Add leading-zero or prefix vanity options",[132],{"id":84,"by":85,"text":86},[134,141],{"value":135,"source":64,"evidence":136},"Why does the output say not prime then prime?",[137],{"id":138,"by":139,"text":140},"46518785","mlyle","Attempt 168: cb80ebbd975f0028... not prime [PRIME] Found after 168 attempts! Commit: cb80ebbd975f00288dca70d8fa735c688755f947 Why does it say not prime then prime?",{"value":142,"source":64,"evidence":143},"Why is the commit slow at 30-120 seconds?",[144],{"id":145,"by":103,"text":146},"46519606","30-120 seconds sounds surprisingly long for ~368 attempts, do you know which part(s) the slowness comes from?",[148,155,161],{"value":149,"source":64,"evidence":150},"git-vanity-hash",[151],{"id":152,"by":153,"text":154},"46519864","yencabulator","https:\u002F\u002Fgithub.com\u002Fprasmussen\u002Fgit-vanity-hash",{"value":156,"source":64,"evidence":157},"git-vanity (tochev)",[158],{"id":159,"by":103,"text":160},"46525336","This already exists btw https:\u002F\u002Fgithub.com\u002Ftochev\u002Fgit-vanity",{"value":162,"source":64,"evidence":163},"git-vanity-sha",[164],{"id":165,"by":166,"text":167},"46527687","brw","What about changing the committer timestamp slightly until you find a match like https:\u002F\u002Fgithub.com\u002Fmattbaker\u002Fgit-vanity-sha? That would make it entirely invisible",{"comments":33,"answered":35,"key":169},[170,173,176],{"id":171,"text":172},"46522554","It is now a proper git trailer, I think.",{"id":174,"text":175},"46521881","Maths saved the day again! I added a section to the README and pages site noting your logic.",{"id":177,"text":178},"46522512","I added the trailer syntax, and rewrote git-prime history to ensure all commits are now number theoretic certified. If you wish to do the same in your own repo I added a script…",{"commenters":180,"max_depth":181,"maker_replies":33,"first_comment_mins":182,"lifespan_hours":183},27,4,17,170,[185,187,191,193,196,198,202,206,208,211,213,216,218,219,221,225,228,232,235,239,242,244,247,251,252,254,257,259,261,264,266,268,270,271,272,275,279,282,286,288,290,292,293,294,297,298,300,301,302,304,307,309,313,315],[122,39,44,186,123,39],"project\u002Fneutral\u002Fdesign",[188,39,39,189,190,39],"46521312","commenter\u002Fneutral\u002Fdocs","AaronFriel",[192,39,39,189,127,39],"46521421",[194,39,44,195,127,39],"46521411","project\u002Fneutral\u002Fdocs",[171,39,39,197,11,34],"maker\u002Fpositive\u002Fexecution",[199,34,44,200,201,39],"46519035","project\u002Fneutral\u002Fidea","rbongers",[203,34,39,204,205,39],"46520001","commenter\u002Fneutral\u002Fidea","nlehuen",[207,34,44,200,205,39],"46520143",[209,34,39,204,210,39],"46520516","cluckindan",[174,34,39,212,11,34],"maker\u002Fpositive\u002Fdocs",[214,34,44,200,215,39],"46520220","perrygeo",[126,32,44,217,127,39],"project\u002Fmixed\u002Fdesign",[177,32,39,197,11,34],[138,44,34,220,139,39],"project\u002Fcritical\u002Fexecution",[222,44,39,223,224,39],"46519090","commenter\u002Fneutral\u002Fnone","themafia",[226,44,39,227,11,34],"46521885","maker\u002Fpositive\u002Fidea",[229,44,44,230,231,39],"46519421","project\u002Fneutral\u002Fexecution","cobbal",[233,44,39,234,11,34],"46521883","maker\u002Fneutral\u002Fexecution",[236,181,39,237,238,39],"46530908","other\u002Fneutral\u002Fnone","extraduder_ire",[240,47,44,200,241,39],"46518755","wiml",[243,47,39,227,11,34],"46521899",[245,35,34,246,127,39],"46521475","project\u002Fcritical\u002Fdesign",[248,249,44,200,250,39],"46519534",7,"dudeinjapan",[152,249,39,237,153,39],[253,249,39,204,250,39],"46523394",[255,249,44,200,256,39],"46520528","aidenn0",[258,249,44,200,250,39],"46523384",[260,249,39,227,11,34],"46521943",[84,262,47,263,85,39],8,"project\u002Fpositive\u002Fidea",[265,262,39,227,11,34],"46521907",[267,262,44,200,85,39],"46524845",[269,262,39,234,11,34],"46525182",[159,262,39,237,103,39],[165,262,44,200,166,39],[273,262,39,274,11,34],"46536892","maker\u002Fneutral\u002Fidea",[276,277,44,186,278,39],"46521101",9,"libeclipse",[280,277,39,281,11,34],"46521915","maker\u002Fneutral\u002Fdesign",[283,284,47,263,285,39],"46518777",10,"adzm",[287,284,39,227,11,34],"46521908",[55,289,39,263,11,34],11,[145,289,34,291,103,39],"project\u002Fcritical\u002Fperformance",[67,289,34,291,68,39],[102,289,34,291,103,39],[295,289,39,296,11,34],"46521920","maker\u002Fneutral\u002Fperformance",[110,289,44,230,111,39],[299,289,44,230,68,39],"46521125",[88,289,39,227,11,34],[114,289,44,230,115,39],[95,289,34,303,96,39],"project\u002Fcritical\u002Fprivacy",[305,289,39,306,11,34],"46521939","maker\u002Fneutral\u002Fprivacy",[308,289,39,223,96,39],"46542844",[310,289,39,311,312,39],"46521947","commenter\u002Fcritical\u002Fprivacy","fragmede",[314,289,39,237,238,39],"46530874",[316,317,39,318,319,39],"46525229",12,"other\u002Fcritical\u002Fidea","cornonthecobra",[],[322,327,331,335,340,345],{"id":323,"name":324,"points":325,"category":326},"46454693","OpenWorkers",500,"infrastructure",{"id":328,"name":329,"points":330,"category":20},"46491749","taws",390,{"id":332,"name":333,"points":334,"category":20},"46511469","Prism.Tools",380,{"id":336,"name":337,"points":338,"category":339},"46499646","DoNotNotify",347,"productivity",{"id":341,"name":342,"points":343,"category":344},"46488654","how browsers work",302,"learning_science",{"id":346,"name":347,"points":348,"category":349},"46501137","Tailsnitch",280,"security_privacy",31,false,"v2",{"id":354,"name":5,"line":6,"ai":351,"cat":20,"year":13,"points":14,"comments":15,"rec":29,"s":355,"top":18,"kw":356,"maker":11,"domain":10,"tier":19,"attempts":39,"strip":357,"url":9,"mix":358,"praise":81,"objection":92,"sub":21},46454369,-0.1,[24,25,26,27,28],"3030330030103030130305300330501103331000",[32,33,34,35],1794036688529]