FireIsWebsiteThe website of FireIsGoodhttps://fireis.dev/The Longest Joke in the Worldhttps://fireis.dev/blog/the-longest-joke-in-the-world/https://fireis.dev/blog/the-longest-joke-in-the-world/A short history and re-hostingSun, 28 Apr 2024 00:00:00 GMT<blockquote> <p><strong>If you just want to read the text, <a href="#the-joke">skip to the joke</a>.</strong></p> </blockquote> <p>The seemingly longest joke in the world—at least as far as googling that specific phrase is concerned— seems to be an old site by the name of <a href="https://longestjokeintheworld.com">The Longest Joke in the World</a>. It's a pretty classic website which seems to have been written in 2007 by the timestamp on the website itself. There is also a separate site called <a href="https://natethesnake.com">Nate the Snake</a> which has a very similar text with a convenient audio narrated version.</p> <p>From some basic research (asking my friend to google it for me), I found that there are a few sources recounting its history. I found these two sources' formatting a little inadequate, so I thought it might be funny to have a <em>third</em> repost of the same joke but with the authorship information and a bit of (other people's) research included.</p> <h2>History</h2> <p><strong>May 6th, 2007</strong> – Original website <a href="https://longestjokeintheworld.com"><em>The Longest Joke in the World</em></a> is created</p> <p>The original site you instantly find is simply named The Longest Joke in the World.com). It's an old looking site with the entire story and an addendum claiming that "joke was also a personality profile test" which lists ways of reading the document and associated predictions about them. Below all of this there is one last section revealing that the joke is 42 meters from top to bottom.</p> <p>While there is no given date of creation, a <a href="https://www.whois.com/whois/longestjokeintheworld.com">Whois lookup</a> notes that the domain was registered on May 6th, 2007. There is also a seemingly broken note at the bottom listing "Visitors since May 6, 2007:" which seems to indicate a similar original creation date.</p> <p>As for styles, it is—for a lack of better ways to say it—hard to look at. The content is squished into an extremely thin box and has a bunch of hard wraps in the text that break up the flow. As revealed at the bottom of the page, the whole joke is said to measure 42 meters—thus being the literal 'longest joke' in existence.</p> <p><img src="@/images/longest-joke-original-website.png" alt="Original website" /></p> <p>For web developer nerds, the entire thing is in a table consisting of a single column which has inline styles of the exact width and height to display at. It's honestly quite incredible how jank it is. Funnily enough, this exact jank spurred on the next development—someone re-hosting the site with better styles.</p> <hr /> <p><strong>May 3rd, 2011</strong> – Re-hosted website <a href="https://natethesnake.com"><em>Nate the Snake</em></a> is created</p> <p>Four years after the original, we see the creation of a site just hosting the contents of the previous site in a much more readable format. It is essentially the same text with some grammatical fixes and a much wider box for the content. At the top there is a 1 hour and 7 minute audio clip by someone named <a href="https://linktr.ee/ericzinkhon">Eric Zinkhon</a> narrating the entire story. The addendum has been removed and a footer has been added with a link to mail the website's creator and a button to donate to the author via a service called <a href="https://www.dash.org">Dash</a>.</p> <p>This site is listed at the top of the <a href="https://www.reddit.com/r/NateTheSnake/">r/NateTheSnake</a> subreddit to this day.</p> <p>Another quick <a href="https://www.whois.com/whois/natethesnake.com">Whois lookup</a> notes that the domain was registered on May 3rd, 2011.</p> <p><img src="@/images/nate-the-snake-website.png" alt="Nate the Snake website" /></p> <p>For web developer nerds, this site is a lot cleaner with the HTML just being a <code>&lt;body&gt;</code> containing the paragraph elements. There's even a <code>&lt;style&gt;</code> tag and actual classes to style things! The background is just a static noise PNG file.</p> <hr /> <p><strong>March 23rd, 2015</strong> – Comment from <a href="https://longestjokeintheworld.com"><em>The Longest Joke in the World</em></a>'s creator</p> <p>Years after the original website was created, we get a <a href="https://www.reddit.com/r/IsItBullshit/comments/2zhlsd/comment/cpobl2d/">comment on a post</a> in the r/IsItBullshit subreddit in March 23rd, 2015 by someone claiming to be the owner of the website. They introduce themself as Bryant Oden and say that they didn't write it and couldn't find the original author. The comment goes on to say that the site isn't the literal longest joke in the world and that the addendum was made up.</p> <p>For verification, the user says that they added the text "[reddit verification]" to the site <a href="https://www.songdrops.com">Songdrops</a> which can be verified to have happened some time between <a href="https://web.archive.org/web/20150323002813/http://www.songdrops.com:80/">March 23rd, 2015</a> and <a href="https://web.archive.org/web/20150406034323/http://www.songdrops.com/">April 6th, 2015</a>.</p> <hr /> <p><strong>October 30, 2020</strong> – Post from <a href="https://natethesnake.com"><em>Nate the Snake</em></a>'s creator</p> <p>A few years later, the creator of the re-hosted website titled <a href="https://www.reddit.com/jldbra/">I host natethesnake.com and would like to answer your questions.</a>. The creator notes that they did it after being annoyed by the formatting. They also said they couldn't find the author.</p> <hr /> <p><strong>November 6th, 2021</strong> – Analysis from a Reddit post "<a href="https://www.reddit.com/qobeny/">Tracing Nate's History</a>"</p> <p>Next in history seems to be largest research I found into this comes from a Reddit post titled Tracing Nate's History written on November 6th, 2021. This post covers the history of the original text in a lot more depth and was what sent me down this rabbit hole.</p> <p>&lt;blockquote&gt;‘Longest Joke’ is mostly the same text as featured on &lt;a href="https://natethesnake.com"&gt;natethesnake.com&lt;/a&gt;, with a few exceptions. Firstly, the host of &lt;a href="https://natethesnake.com"&gt;natethesnake.com&lt;/a&gt; freely admits that he edited some sections to fix grammatical errors and other flow issues. Secondly, the ‘Longest Joke’ page includes an appendage at the end of the joke which claims that it is part of a psychology study that would be used for a master’s thesis. &lt;footer&gt; &lt;cite&gt;– Jack, &lt;a href="https://www.reddit.com/qobeny/"&gt;Tracing Nate's history&lt;/a&gt;&lt;/cite&gt; &lt;/footer&gt; &lt;/blockquote&gt;</p> <p>I would recommend reading <a href="https://www.reddit.com/qobeny/">the post</a> if you want further information about the original text. It is a lot more in depth than this post and has sources (wow!) that this lacks.</p> <h2>The Joke</h2> <p><strong>Lost in the Desert</strong></p> <p>So, there's a man crawling through the desert.</p> <p>He'd decided to try his SUV in a little bit of cross-country travel, had great fun zooming over the badlands and through the sand, got lost, hit a big rock, and then he couldn't get it started again. There were no cell phone towers anywhere near, so his cell phone was useless. He had no family, his parents had died a few years before in an auto accident, and his few friends had no idea he was out here.</p> <p>He stayed with the car for a day or so, but his one bottle of water ran out and he was getting thirsty. He thought maybe he knew the direction back, now that he'd paid attention to the sun, and thought he'd figured out which way was north, so he decided to start walking. He figured he only had to go about 30 miles or so and he'd be back to the small town he'd gotten gas in last.</p> <p>He thinks about walking at night to avoid the heat and sun, but based upon how dark it actually was the night before, and given that he has no flashlight, he's afraid that he'll break a leg or step on a rattlesnake. So, he puts on some sun block, puts the rest in his pocket for reapplication later, brings an umbrella he'd had in the back of the SUV with him to give him a little shade, pours the windshield wiper fluid into his water bottle in case he gets that desperate, brings his pocket knife in case he finds a cactus that looks like it might have water in it, and heads out in the direction he thinks is right.</p> <p>He walks for the entire day. By the end of the day he's really thirsty. He's been sweating all day, and his lips are starting to crack. He's reapplied the sunblock twice, and tried to stay under the umbrella, but he still feels sunburned. The windshield wiper fluid sloshing in the bottle in his pocket is really getting tempting now. He knows that it's mainly water and some ethanol and coloring, but he also knows that they add some kind of poison to it to keep people from drinking it. He wonders what the poison is, and whether the poison would be worse than dying of thirst.</p> <p>He pushes on, trying to get to that small town before dark.</p> <p>By the end of the day, he starts getting worried. He figures he's been walking at least three miles an hour, according to his watch for over ten hours. That means that if his estimate was right, he should be close to the town. Unfortunately, he doesn't recognize any of this. He had to cross a dry creek bed a mile or two back, and he doesn't remember coming through it in the SUV. He figures that maybe he got his direction off just a little and that the dry creek bed was just off to one side of his path. He tells himself that he's close, and that after dark he'll start seeing the town lights over one of these hills. That'll be all he needs.</p> <p>As it gets dim enough that he starts stumbling over small rocks and things, he finds a spot and sits down to wait for full dark and the town lights.</p> <p>Full dark comes before he knows it. He must have dozed off. He stands back up and turns all the way around. He sees nothing but stars.</p> <p>He wakes up the next morning feeling absolutely lousy. His eyes are gummy and his mouth and nose feel like they're full of sand. He’s so thirsty that he can't even swallow. He barely got any sleep because it was so cold. He'd forgotten how cold it got at night in the desert and hadn't noticed it the night before because he'd been in his car.</p> <p>He knows the Rule of Threes - three minutes without air, three days without water, three weeks without food - then you die. Some people can make it a little longer, in the best situations. The desert heat and having to walk and sweat isn't the best situation to be in without water. Unless he finds water, he figures, this is his last day.</p> <p>He rinses out his mouth with a little of the windshield wiper fluid. He waits for a while after spitting that little bit out to see if his mouth goes numb, or he feels dizzy or something. Has his mouth gone numb? Is it just in his mind? He's not sure. He'll go a little farther, and if he still doesn't find water, he'll try drinking some of the fluid.</p> <p>Then he has to face his next, harder question - which way does he go from here? Does he keep walking the same way as yesterday (assuming that he still knows which way that is), or does he try a new direction? He has no idea what to do.</p> <p>Looking at the hills and dunes around him, he thinks he knows the direction he was heading before. Just going by a feeling, he points himself somewhat to the left of that, and starts walking.</p> <p>As he walks, the day starts heating up. The desert, too cold just a couple of hours before, soon becomes an oven again. He sweats a little at first, and then stops. He starts getting worried at that. He knows that when you stop sweating, you’re in trouble. It’s usually right before heat stroke..</p> <p>He decides that it's time to try the windshield wiper fluid. He can't wait any longer - if he passes out, he's dead. He stops in the shade of a large rock, takes the bottle out, opens it, and takes a mouthful. He slowly swallows it, making it last as long as he can. It feels so good in his dry and cracked throat that he doesn't even care about the nasty taste. He takes another mouthful, and makes it last too. Slowly, he drinks half the bottle. He figures that since he's drinking it, he might as well drink enough to make some difference and keep himself from passing out.</p> <p>He's quit worrying about the denaturing of the wiper fluid. If it kills him, it kills him. If he didn't drink it, he'd die anyway. Besides, he's pretty sure that whatever substance they denature the fluid with is just designed to make you sick: their way of keeping winos from buying cheap wiper fluid for the ethanol content. He can handle throwing up if it comes to that.</p> <p>He walks. He walks in the hot, dry, windless desert. Sand, rocks, hills, dunes, the occasional scrawny cactus or dried bush. No sign of water. Sometimes he'll see a little movement to one side or the other, but whatever moved is usually gone before he can focus his eyes on it. Probably birds, lizards, or mice. Maybe snakes, though they usually move more at night. He's careful to stay away from the movements.</p> <p>After a while, he begins to stagger. He's not sure if it's fatigue, heat stroke finally catching him, or maybe he was wrong and the denaturing of the wiper fluid was worse than he thought. He tries to steady himself and keep going.</p> <p>After more walking, he comes to a large stretch of sand. This is good! He knows he passed over a stretch of sand in the SUV - he remembers doing donuts in it, or at least he thinks he remembers it; he's getting woozy enough and tired enough that he's not sure what he remembers anymore or if he's hallucinating. He thinks he remembers it, so he heads off into it, trying to get to the other side, hoping that it gets him closer to the town.</p> <p>He was heading for a town, wasn't he? He thinks he was. He isn't sure anymore. He's not even sure how long he's been walking anymore. Is it still morning? Has it moved into afternoon, and the sun is going down again? It must be afternoon; it seems like it's been too long since he started out.</p> <p>He walks through the sand.</p> <p>After a while, he comes to a big dune in the sand. This is bad. He doesn't remember any dunes from when he was driving over the sand in his SUV. At least he doesn't think he remembers any. This is bad.</p> <p>All the same, he has no other direction to go. Too late to turn back now. He figures that he'll get to the top of the dune and see if he can see anything from there that can help him find the town. He keeps going up the dune.</p> <p>Halfway up, he slips in the bad footing of the sand for the second or third time and falls to his knees. He doesn't feel like getting back up, since he'll just fall down again. He keeps going up the dune on his hand and knees.</p> <p>While crawling, if his throat weren't so dry, he'd laugh. He's finally gotten to the hackneyed image of a man lost in the desert, crawling through the sand on his hands and knees. It would be the perfect image, he imagines, if only his clothes were more ragged. The people crawling through the desert in the cartoons always had ragged clothes, but his have lasted without any rips so far. Somebody will probably find his desiccated corpse half buried in the sand years from now, and his clothes will still be in fine shape - shake the sand out, give them a good wash, and they'd be wearable again. He wishes his throat were wet enough to laugh. He coughs a little instead, and it hurts.</p> <p>He finally makes it to the top of the sand dune. Now that he's at the top, he struggles a little, but manages to stand up and look around. All he sees is sand. Sand and more sand. Behind him, about a mile away, he thinks he sees the rocky ground he left to head into this sand. Ahead of him, more dunes, more sand. This isn't where he drove his SUV. This is Hell. Or close enough.</p> <p>Again, he doesn't know what to do. He decides to drink the rest of the wiper fluid while figuring it out. He takes out the bottle and starts removing the cap when he glances to the side and sees something. Something in the sand. At the bottom of the dune, off to the side, he sees something strange. It's a flat area, in the sand. He stops opening the bottle and tries to look closer. The area seems to be circular, and it's dark: darker than the sand, and there seems to be something in the middle of it, but he can't tell what it is, so he looks as hard as he can but still can't tell from here. He's going to have to go down there and look.</p> <p>He puts the bottle back into his pocket, and starts to stumble down the dune. After a few steps, he realizes that he's in trouble; he's not going to be able to keep his balance. After a couple more sliding, tottering steps, he falls and starts to roll down the dune. The sand it so hot that he thinks he's caught fire on the way down - like a movie car wreck flashing into flames as it goes over the cliff, before it ever even hits the ground. He closes his eyes and mouth, covers his face with his hands, and waits to stop rolling.</p> <p>He stops at the bottom of the dune. After a minute or two, he finds enough energy to try to sit up and get the sand out of his face and clothes. When he clears his eyes enough, he looks around to make sure that the dark spot in the sand it still there and he hadn't just imagined it.</p> <p>Seeing the large, flat, dark spot on the sand still there, he crawls towards it. He'd get up and walk towards it, but he doesn't seem to have the energy to get up and walk right now. He must be in the final stages of dehydration he figures as he crawls. If this place in the sand doesn't have water, he'll likely never make it anywhere else. This is his last chance.</p> <p>He gets closer and closer, but still can't see what's in the middle of the dark area. It’s hard to focus, and lifting his head up to look takes so much effort that he gives up trying. He just keeps crawling.</p> <p>Finally, he reaches the area he'd seen from the dune. It takes him a minute of crawling on it before he realizes that he's no longer on sand - he's now crawling on some kind of dark stone. Stone with some kind of marking on it - a pattern cut into the stone. He's too tired to stand up and try to see what the pattern is, so he just keeps crawling. He crawls towards the center where his blurry eyes still see something in the middle of the dark stone area.</p> <p>His mind, detached in a strange way, notes that either his hands and knees are so burnt by the sand that they no longer feel pain, or that this dark stone, in the middle of a burning desert with a pounding, punishing sun overhead, doesn't seem to be hot. It almost feels cool. He considers lying down on the nice cool surface.</p> <p>Cool, dark stone. Not a good sign. He must be hallucinating this. He's probably in the middle of a patch of sand, already lying face down and dying, and just imagining this whole thing. A desert mirage. Soon the beautiful women carrying pitchers of water will come up and start giving him a drink. Then he'll know he's gone.</p> <p>He decides against laying down on the cool stone. If he's going to die here in the middle of this hallucination, he at least wants to see what's in the center before he goes. He keeps crawling.</p> <p>It's the third time that he hears the voice before he realizes what he's hearing. He would swear that someone just said, "Greetings, traveler. You do not look well. Do you hear me?"</p> <p>He stops crawling. He tries to look up from where he is on his hands and knees, but it's too much effort to lift his head. So he tries something different: he rolls over and leans back trying to sit up on the stone. After a few seconds, he catches his balance, avoids falling on his face, sits up, and tries to focus his eyes. Blurry. He rubs his eyes with the back of his hands and tries again. Better this time.</p> <p>Yep. He can see. He's sitting in the middle of a large, flat, dark expanse of stone. Directly next to him, about three feet away, is a white post or pole about two inches in diameter and sticking about four or five feet out of the stone, at an angle.</p> <p>And wrapped around this white rod is what must be a fifteen foot long desert diamondback rattlesnake, with a hovering tail and rattle seemingly prepared to start rattling, looking directly at him.</p> <p>He stares at the snake in shock. He doesn't have the energy to get up and run away. He doesn't even have the energy to crawl away. This is it: his final resting place. No matter what happens, he's not going to be able to move from this spot.</p> <p>Well, at least dying from a bite from this monster should be quicker than dying of thirst. He'll face his end like a man. He struggles to sit up a little straighter. The snake keeps watching him. He lifts one hand and flicks it in the snake's direction, feebly. The snake watches the hand for a moment, then goes back to watching the man, looking into his eyes.</p> <p>Hmmm. Maybe the snake has no interest in biting him. It hasn't rattled yet - that’s a good sign. Maybe he isn't going to die of snake bite after all.</p> <p>He then remembers that he'd looked up when he'd reached the center here because he thought he'd heard a voice. He is still very woozy; he feels like he might pass out soon. The sun still beats down on him even though he is now on cool stone. He still doesn't have anything to drink. Although maybe he had actually heard a voice. This stone doesn't look natural. Nor does that white post sticking up out of the stone. Someone must have built this. Maybe they are still nearby. Maybe that was who talked to him. Maybe this snake is even their pet, and that's why it isn't biting.</p> <p>He tries to clear his throat to say, "Hello," but he’s too dry. All that comes out is a coughing or wheezing sound. There's no way he's going to be able to talk without something to drink. He feels his pocket, and the bottle with the wiper fluid is still there. He shakily pulls out the bottle, almost losing his balance and falling on his back in the process. This isn't good. He doesn't have much time left by his reckoning before he passes out.</p> <p>He gets the bottle open, manages to get the bottle to his lips, and pours some of the fluid into his mouth. He sloshes it around, and then swallows it. He coughs a little. His throat feels better. Maybe he can talk now.</p> <p>He tries again. Ignoring the snake, he turns to look around him, hoping to spot the owner of this place, and croaks out, "Hello? Is there anyone here?"</p> <p>He hears, from his side, "Greetings. What is it that you want?"</p> <p>He turns his head back towards the snake. That's where the sound seemed to come from. The only thing he can think of is that there must be a speaker hidden under the snake, or maybe built into that post. He decides to try asking for help.</p> <p>"Please," he croaks again, suddenly feeling dizzy, "I'd love to not be thirsty anymore. I've been without water for a long time. Can you help me?"</p> <p>Looking in the direction of the snake, hoping to see where the voice was coming from this time, he is shocked to see the snake rear back, open its mouth, and speak. He hears it say, as the dizziness overtakes him and he falls forward, face first on the stone, "Very well. Coming up."</p> <p>A piercing pain shoots through his shoulder. Suddenly he is awake. He sits up and grabs his shoulder, wincing at the throbbing pain. He's momentarily disoriented as he looks around, and then he remembers: the crawl across the sand, the dark area of stone, the snake. He sees the snake, still wrapped around the tilted white post, still looking at him.</p> <p>He reaches up and feels his shoulder, where it hurts. It feels slightly wet. He pulls his fingers away and looks at them - blood. He feels his shoulder again - it feels like his shirt has two holes in it - two puncture holes. They match up with the two aching spots of pain on his shoulder. He has been bitten. By the snake.</p> <p>"It'll feel better in a minute." He looks up - it's the snake talking. He hadn't dreamed it. Suddenly he notices - he's not dizzy anymore. And more importantly, he's not thirsty anymore - at all!</p> <p>"Have I died? Is this the afterlife? Why are you biting me in the afterlife?"</p> <p>"Sorry about that, but I had to bite you," says the snake. "That's the way I work. It all comes through the bite. Think of it as natural medicine."</p> <p>"You bit me to help me? Why aren't I thirsty anymore? Did you give me a drink before you bit me? How did I drink enough while unconscious to not be thirsty anymore? I haven't had a drink for over two days. Well, except for the windshield wiper fluid... hold it, how in the world does a snake talk? Are you real? Are you some sort of Disney animation?"</p> <p>"No," says the snake, "I'm real. As real as you or anyone is, anyway. I didn't give you a drink. I bit you. That's how it works, it's what I do. I bite. Plus I don't have hands to give you a drink, even if I had water just sitting around here."</p> <p>The man sat stunned for a minute. Here he was, sitting in the middle of the desert on some strange stone that should be hot but wasn't, talking to a snake that could talk back and had just bitten him. And he felt better. Not great - he was still starving and exhausted, but much better - he was no longer thirsty. He had started to sweat again, but only slightly. He felt hot, in this sun, but it was starting to get lower in the sky, and the cool stone beneath him was a relief he could notice now that he was no longer dying of thirst.</p> <p>"I might suggest that we take care of that methanol you now have in your system with the next request," continued the snake. "I can guess why you drank it, but I'm not sure how much you drank, or how much methanol was left in the wiper fluid. That stuff is nasty. It'll make you go blind in a day or two, if you drank enough of it."</p> <p>"Ummm, n-next request?" said the man. He put his hand back on his hurting shoulder and backed away from the snake a little.</p> <p>"That's the way it works. If you like, that is," explained the snake. "You get three requests. Call them wishes, if you wish." The snake grinned at his own joke, and the man drew back a little further from the show of fangs.</p> <p>"But there are rules," the snake continued. "The first request is free. The second requires an agreement of secrecy. The third requires the binding of responsibility." The snake looks at the man seriously.</p> <p>"By the way," the snake says suddenly, "my name is Nathan. Old Nathan, Samuel used to call me. He gave me the name. Before that, most of the Bound used to just call me 'Snake'. But that got old, and Samuel wouldn't stand for it. He said that anything that could talk needed a name. He was big into names. You can call me Nate, if you wish." Again, the snake grinned. "Sorry if I don't offer to shake, but I think you can understand - my shake sounds somewhat threatening." The snake give his rattle a little shake.</p> <p>"Umm, my name is Jack," said the man, trying to absorb all of this. "Jack Samson."</p> <p>"Can I ask you a question?" Jack says suddenly. "What happened to the venom...umm, in your bite. Why aren't I dying now? How did you do that? What do you mean by that's how you work?"</p> <p>"That's more than one question," grins Nate. "But I'll still try to answer all of them. First, yes, you can ask me a question." The snake's grin gets wider. "Second, the venom is in you. It changed you. You now no longer need to drink. That's what you asked for. Or, well, technically, you asked to not be thirsty any more - but 'any more' is such a vague term. I decided to make it permanent - now, as long as you live, you shouldn't need to drink much at all. Your body will conserve water very efficiently. You should be able to get enough just from the food you eat - much like a creature of the desert. You've been changed.</p> <p>"For the third question," Nate continues, "you are still dying. Besides the effects of that methanol in your system, you're a man - and men are mortal. In your current state, I give you no more than about another 50 years. Assuming you get out of this desert, alive, that is." Nate seemed vastly amused at his own humor, and continued his wide grin.</p> <p>"As for the fourth question," Nate said, looking more serious as far as Jack could tell, as Jack was just now working on his ability to read talking-snake emotions from snake facial features, "first you have to agree to make a second request and become bound by the secrecy, or I can't tell you."</p> <p>"Wait," joked Jack, "isn't this where you say you could tell me, but you'd have to kill me?"</p> <p>"I thought that was implied." Nate continued to look serious.</p> <p>"Ummm...yeah." Jack leaned back a little as he remembered again that he was talking to a fifteen foot venomous reptile with a reputation for having a nasty temper. "So, what is this 'Bound by Secrecy' stuff, and can you really stop the effects of the methanol?" Jack thought for a second. "And, what do you mean methanol, anyway? I thought these days they use ethanol in wiper fluid, and just denature it?"</p> <p>"They may, I don't really know," said Nate. "I haven't gotten out in a while. Maybe they do. All I know is that I smell methanol on your breath and on that bottle in your pocket. And the blue color of the liquid when you pulled it out to drink some let me guess that it was wiper fluid. I assume that they still color wiper fluid blue?"</p> <p>"Yeah, they do," said Jack.</p> <p>"I figured," replied Nate. "As for being bound by secrecy - with the fulfillment of your next request, you will be bound to say nothing about me, this place, or any of the information I will tell you after that, when you decide to go back out to your kind. You won't be allowed to talk about me, write about me, use sign language, charades, or even act in a way that will lead someone to guess correctly about me. You'll be bound to secrecy. Of course, I'll also ask you to promise not to give me away, and as I'm guessing that you're a man of your word, you'll never test the binding anyway, so you won't notice." Nate said the last part with utter confidence.</p> <p>Jack, who had always prided himself on being a man of his word, felt a little nervous at this. "Ummm, hey, Nate, who are you? How did you know that? Are you, umm, omniscient, or something?"</p> <p>Well, Jack," said Nate sadly, "I can't tell you that, unless you make the second request." Nate looked away for a minute, then looked back.</p> <p>"Umm, well, ok," said Jack, "what is this about a second request? What can I ask for? Are you allowed to tell me that?"</p> <p>"Sure!" said Nate, brightening. "You're allowed to ask for changes. Changes to yourself. They're like wishes, but they can only affect you. Oh, and before you ask, I can't give you immortality. Or omniscience. Or omnipresence, for that matter. Though I might be able to make you gaseous and yet remain alive, and then you could spread through the atmosphere and sort of be omnipresent. But what good would that be - you still wouldn't be omniscient and thus still could only focus on one thing at a time. Not very useful, at least in my opinion." Nate stopped when he realized that Jack was staring at him.</p> <p>"Well, anyway," continued Nate, "I'd probably suggest giving you permanent good health. It would negate the methanol now in your system, you'd be immune to most poisons and diseases, and you'd tend to live a very long time, barring accident, of course. And you'll even have a tendency to recover from accidents well. It always seemed like a good choice for a request to me."</p> <p>"Cure the methanol poisoning, huh?" said Jack. "And keep me healthy for a long time? Hmmm. It doesn't sound bad at that. And it has to be a request about a change to me? I can't ask to be rich, right? Because that's not really a change to me?"</p> <p>"Right," nodded Nate.</p> <p>"Could I ask to be a genius and permanently healthy?" Jack asked, hopefully.</p> <p>"That takes two requests, Jack."</p> <p>"Yeah, I figured so," said Jack. "But I could ask to be a genius? I could become the smartest scientist in the world? Or the best athlete?"</p> <p>"Well, I could make you very smart," admitted Nate, "but that wouldn't necessarily make you the best scientist in the world. Or, I could make you very athletic, but it wouldn't necessarily make you the best athlete either. You've heard the saying that 99% of genius is hard work? Well, there's some truth to that. I can give you the talent, but I can't make you work hard. It all depends on what you decide to do with it."</p> <p>"Hmmm," said Jack. "Ok, I think I understand. And I get a third request, after this one?"</p> <p>"Maybe," said Nate, "it depends on what you decide then. There are more rules for the third request that I can only tell you about after the second request. You know how it goes." Nate looked like he'd shrug, if he had shoulders.</p> <p>"Ok, well, since I'd rather not be blind in a day or two, and permanent health doesn't sound bad, then consider that my second request. Officially. Do I need to sign in blood or something?"</p> <p>"No," said Nate. "Just hold out your hand. Or heel." Nate grinned. "Or whatever part you want me to bite. I have to bite you again. Like I said, that's how it works - the venom, you know," Nate said apologetically.</p> <p>Jack winced a little and felt his shoulder, where the last bite was. Hey, it didn't hurt any more. Just like Nate had said. That made Jack feel better about the biting business. But still, standing still while a fifteen foot snake sunk it's fangs into you. Jack stood up. Ignoring how good it felt to be able to stand again, and the hunger starting to gnaw at his stomach, Jack tried to decide where he wanted to get bitten. Despite knowing that it wouldn't hurt for long, Jack knew that this wasn't going to be easy.</p> <p>"Hey, Jack," Nate suddenly said, looking past Jack towards the dunes behind him, "is that someone else coming up over there?"</p> <p>Jack spun around and looked. Who else could be out here in the middle of nowhere? And did they bring food?</p> <p>Wait a minute, there was nobody over there. What was Nate...</p> <p>Jack let out a bellow as he felt two fangs sink into his rear end, through his jeans...</p> <p>Jack sat down carefully, favoring his more tender buttock. "I would have decided, eventually, Nate. I was just thinking about it. You didn't have to hoodwink me like that."</p> <p>"I've been doing this a long time, Jack," said Nate, confidently. "You humans have a hard time sitting still and letting a snake bite you - especially one my size. And besides, admit it - it's only been a couple of minutes and it already doesn't hurt any more, does it? That's because of the health benefit with this one. I told you that you'd heal quickly now."</p> <p>"Yeah, well, still," said Jack, "it's the principle of the thing. And nobody likes being bitten in the butt! Couldn't you have gotten my calf or something instead?"</p> <p>"More meat in the typical human butt," replied Nate. "And less chance you accidentally kick me or move at the last second."</p> <p>"Yeah, right. So, tell me all of these wonderful secrets that I now qualify to hear," answered Jack.</p> <p>"Ok," said Nate. "Do you want to ask questions first, or do you want me to just start talking?"</p> <p>"Just talk," said Jack. "I'll sit here and try to not think about food."</p> <p>"We could go try to rustle up some food for you first, if you like," answered Nate.</p> <p>"Hey! You didn't tell me you had food around here, Nate!" Jack jumped up. "What do we have? Am I in walking distance to town? Or can you magically whip up food along with your other powers?" Jack was almost shouting with excitement. His stomach had been growling for hours.</p> <p>"I was thinking more like I could flush something out of its hole and bite it for you, and you could skin it and eat it. Assuming you have a knife, that is," replied Nate, with the grin that Jack was starting to get used to.</p> <p>"Ugh," said Jack, sitting back down. "I think I'll pass. I can last a little longer before I get desperate enough to eat desert rat, or whatever else it is you find out here. And there's nothing to burn - I'd have to eat it raw. No thanks. Just talk."</p> <p>"Ok," replied Nate, still grinning. "But I'd better hurry, before you start looking at me as food.</p> <p>Nate reared back a little, looked around for a second, and then continued. "You, Jack, are sitting in the middle of the Garden of Eden."</p> <p>Jack looked around at the sand and dunes and then looked back at Nate sceptically.</p> <p>"Well, that's the best I can figure it, anyway, Jack," said Nate. "Stand up and look at the symbol on the rock here." Nate gestured around the dark stone they were both sitting on with his nose.</p> <p>Jack stood up and looked. Carved into the stone in a bas-relief was a representation of a large tree. The angled-pole that Nate was wrapped around was coming out of the trunk of the tree, right below where the main branches left the trunk to reach out across the stone. It was very well done - it looked more like a tree had been reduced to almost two dimensions and embedded in the stone than it did like a carving.</p> <p>Jack walked around and looked at the details in the fading light of the setting sun. He wished he'd looked at it while the sun was higher in the sky.</p> <p>Wait! The sun was setting! That meant he was going to have to spend another night out here! Arrrgh!</p> <p>Jack looked out across the desert for a little bit, and then came back and stood next to Nate. "In all the excitement, I almost forgot, Nate," said Jack. "Which way is it back to town? And how far? I'm eventually going to have to head back - I'm not sure I'll be able to survive by eating raw desert critters for long. And even if I can, I'm not sure I'll want to."</p> <p>"It's about 30 miles that way." Nate pointed, with the rattle on his tail this time. As far as Jack could tell, it was a direction at right angles to the way he'd been going when he was crawling here. "But that's 30 miles by the way the crow flies. It's about 40 by the way a man walks. You should be able to do it in about half a day with your improved endurance, if you head out early tomorrow, Jack."</p> <p>Jack looked out the way the snake had pointed for a few seconds more, and then sat back down. It was getting dark. Not much he could do about heading out right now. And besides, Nate was just about to get to the interesting stuff. "Garden of Eden? As best as you can figure it?"</p> <p>"Well, yeah, as best as I and Samuel could figure it anyway," said Nate. "He figured that the story just got a little mixed up. You know, snake, in a 'tree', offering 'temptations', making bargains. That kind stuff. But he could never quite figure out how the Hebrews found out about this spot from across the ocean. He worried about that for a while."</p> <p>"Garden of Eden, hunh?" said Jack. "How long have you been here, Nate?"</p> <p>"No idea, really," replied Nate. "A long time. It never occurred to me to count years, until recently, and by then, of course, it was too late. But I do remember when this whole place was green, so I figure it's been thousands of years, at least."</p> <p>"So, are you the snake that tempted Eve?" said Jack.</p> <p>"Beats me," said Nate. "Maybe. I can't remember if the first one of your kind that I talked to was female or not, and I never got a name, but it could have been. And I suppose she could have considered my offer to grant requests a 'temptation', though I've rarely had refusals."</p> <p>"Well, umm, how did you get here then? And why is that white pole stuck out of the stone there?" asked Jack.</p> <p>"Dad left me here. Or, I assume it was my dad. It was another snake - much bigger than I was back then. I remember talking to him, but I don't remember if it was in a language, or just kind of understanding what he wanted. But one day, he brought me to this stone, told me about it, and asked me to do something for him. I talked it over with him for a while, then agreed. I've been here ever since.</p> <p>"What is this place?" said Jack. "And what did he ask you to do?"</p> <p>"Well, you see this pole here, sticking out of the stone?" Nate loosened his coils around the tilted white pole and showed Jack where it descended into the stone. The pole was tilted at about a 45 degree angle and seemed to enter the stone in an eighteen inch slot cut into the stone. Jack leaned over and looked. The slot was dark and the pole went down into it as far as Jack could see in the dim light. Jack reached out to touch the pole, but Nate was suddenly there in the way.</p> <p>"You can't touch that yet, Jack," said Nate.</p> <p>"Why not?" asked Jack.</p> <p>"I haven't explained it to you yet," replied Nate.</p> <p>"Well, it kinda looks like a lever or something," said Jack. "You'd push it that way, and it would move in the slot."</p> <p>"Yep, that's what it is," replied Nate.</p> <p>"What does it do?" asked Jack. "End the world?"</p> <p>"Oh, no," said Nate. "Nothing that drastic. It just ends humanity. I call it 'The Lever of Doom'." For the last few words Nate had used a deeper, ringing voice. He tried to look serious for a few seconds, and then gave up and grinned.</p> <p>Jack was initially startled by Nate's pronouncement, but when Nate grinned Jack laughed. "Ha! You almost had me fooled for a second there. What does it really do?"</p> <p>"Oh, it really ends humanity, like I said," smirked Nate. "I just thought the voice I used was funny, didn't you?"</p> <p>Nate continued to grin.</p> <p>"A lever to end humanity?" asked Jack. "What in the world is that for? Why would anyone need to end humanity?"</p> <p>"Well," replied Nate, "I get the idea that maybe humanity was an experiment. Or maybe the Big Guy just thought, that if humanity started going really bad, there should be a way to end it. I'm not really sure. All I know are the rules, and the guesses that Samuel and I had about why it's here. I didn't think to ask back when I started here."</p> <p>"Rules? What rules?" asked Jack.</p> <p>"The rules are that I can't tell anybody about it or let them touch it unless they agree to be bound to secrecy by a bite. And that only one human can be bound in that way at a time. That's it." explained Nate.</p> <p>Jack looked somewhat shocked. "You mean that I could pull the lever now? You'd let me end humanity?"</p> <p>"Yep," replied Nate, "if you want to." Nate looked at Jack carefully. "Do you want to, Jack?"</p> <p>"Umm, no." said Jack, stepping a little further back from the lever. "Why in the world would anyone want to end humanity? It'd take a psychotic to want that! Or worse, a suicidal psychotic, because it would kill him too, wouldn't it?"</p> <p>"Yep," replied Nate, "being as he'd be human too."</p> <p>"Has anyone ever seriously considered it?" asked Jack. "Any of those bound to secrecy, that is?"</p> <p>"Well, of course, I think they've all seriously considered it at one time or another. Being given that kind of responsibility makes you sit down and think, or so I'm told. Samuel considered it several times. He'd often get disgusted with humanity, come out here, and just hold the lever for a while. But he never pulled it. Or you wouldn't be here." Nate grinned some more.</p> <p>Jack sat down, well back from the lever. He looked thoughtful and puzzled at the same time. After a bit, he said, "So this makes me the Judge of humanity? I get to decide whether they keep going or just end? Me?"</p> <p>"That seems to be it," agreed Nate.</p> <p>"What kind of criteria do I use to decide?" said Jack. "How do I make this decision? Am I supposed to decide if they're good? Or too many of them are bad? Or that they're going the wrong way? Is there a set of rules for that?"</p> <p>"Nope," replied Nate. "You pretty much just have to decide on your own. It's up to you, however you want to decide it. I guess that you're just supposed to know."</p> <p>"But what if I get mad at someone? Or some girl dumps me and I feel horrible? Couldn't I make a mistake? How do I know that I won't screw up?" protested Jack.</p> <p>Nate gave his kind of snake-like shrug again. "You don't. You just have to try your best, Jack."</p> <p>Jack sat there for a while, staring off into the desert that was rapidly getting dark, chewing on a fingernail.</p> <p>Suddenly, Jack turned around and looked at the snake. "Nate, was Samuel the one bound to this before me?"</p> <p>"Yep," replied Nate. "He was a good guy. Talked to me a lot. Taught me to read and brought me books. I think I still have a good pile of them buried in the sand around here somewhere. I still miss him. He died a few months ago."</p> <p>"Sounds like a good guy," agreed Jack. "How did he handle this, when you first told him. What did he do?"</p> <p>"Well," said Nate, "he sat down for a while, thought about it for a bit, and then asked me some questions, much like you're doing."</p> <p>"What did he ask you, if you're allowed to tell me?" asked Jack.</p> <p>"He asked me about the third request," replied Nate.</p> <p>"Aha!" It was Jack's turn to grin. "And what did you tell him?"</p> <p>"I told him the rules for the third request. That to get the third request you have to agree to this whole thing. That if it ever comes to the point that you really think that humanity should be ended, that you'll come here and end it. You won't avoid it, and you won't wimp out." Nate looked serious again. "And you'll be bound to do it too, Jack."</p> <p>"Hmmm." Jack looked back out into the darkness for a while.</p> <p>Nate watched him, waiting.</p> <p>"Nate," continued Jack, quietly, eventually. "What did Samuel ask for with his third request?"</p> <p>Nate sounded like he was grinning again as he replied, also quietly, "Wisdom, Jack. He asked for wisdom. As much as I could give him."</p> <p>"Ok," said Jack, suddenly, standing up and facing away from Nate, "give it to me.</p> <p>Nate looked at Jack's backside. "Give you what, Jack?"</p> <p>"Give me that wisdom. The same stuff that Samuel asked for. If it helped him, maybe it'll help me too." Jack turned his head to look back over his shoulder at Nate. "It did help him, right?"</p> <p>"He said it did," replied Nate. "But he seemed a little quieter afterward. Like he had a lot to think about."</p> <p>"Well, yeah, I can see that," said Jack. "So, give it to me." Jack turned to face away from Nate again, bent over slightly and tensed up.</p> <p>Nate watched Jack tense up with a little exasperation. If he bit Jack now, Jack would likely jump out of his skin and maybe hurt them both.</p> <p>"You remember that you'll be bound to destroy humanity if it ever looks like it needs it, right Jack?" asked Nate, shifting position.</p> <p>"Yeah, yeah, I got that," replied Jack, eyes squeezed tightly shut and body tense, not noticing the change in direction of Nate's voice.</p> <p>"And," continued Nate, from his new position, "do you remember that you'll turn bright purple, and grow big horns and extra eyes?"</p> <p>"Yeah, yeah...Hey, wait a minute!" said Jack, opening his eyes, straightening up and turning around. "Purple?!" He didn't see Nate there. With the moonlight Jack could see that the lever extended up from its slot in the rock without the snake wrapped around it.</p> <p>Jack heard, from behind him, Nate's "Just Kidding!" right before he felt the now familiar piercing pain, this time in the other buttock.</p> <p>Jack sat on the edge of the dark stone in the rapidly cooling air, his feet extending out into the sand. He stared out into the darkness, listening to the wind stir the sand, occasionally rubbing his butt where he'd been recently bitten.</p> <p>Nate had left for a little while, had come back with a desert-rodent-shaped bulge somewhere in his middle, and was now wrapped back around the lever, his tongue flicking out into the desert night's air the only sign that he was still awake.</p> <p>Occasionally Jack, with his toes absentmindedly digging in the sand while he thought, would ask Nate a question without turning around.</p> <p>"Nate, do accidents count?"</p> <p>Nate lifted his head a little bit. "What do you mean, Jack?"</p> <p>Jack tilted his head back like he was looking at the stars. "You know, accidents. If I accidentally fall on the lever, without meaning to, does that still wipe out humanity?"</p> <p>"Yeah, I'm pretty sure it does, Jack. I'd suggest you be careful about that if you start feeling wobbly," said Nate with some amusement.</p> <p>A little later - "Does it have to be me that pulls the lever?" asked Jack.</p> <p>"That's the rule, Jack. Nobody else can pull it," answered Nate.</p> <p>"No," Jack shook his head, "I meant does it have to be my hand? Could I pull the lever with a rope tied around it? Or push it with a stick? Or throw a rock?"</p> <p>"Yes, those should work," replied Nate. "Though I'm not sure how complicated you could get. Samuel thought about trying to build some kind of remote control for it once, but gave it up. Everything he'd build would be gone by the next sunrise, if it was touching the stone, or over it. I told him that in the past others that had been bound had tried to bury the lever so they wouldn't be tempted to pull it, but every time the stones or sand or whatever had disappeared."</p> <p>"Wow," said Jack, "Cool." Jack leaned back until only his elbows kept him off of the stone and looked up into the sky.</p> <p>"Nate, how long did Samuel live? One of his wishes was for health too, right?" asked Jack.</p> <p>"Yes," replied Nate, "it was. He lived 167 years, Jack."</p> <p>"Wow, 167 years. That's almost 140 more years I'll live if I live as long. Do you know what he died of, Nate?"</p> <p>"He died of getting tired of living, Jack," Nate said, sounding somewhat sad.</p> <p>Jack turned his head to look at Nate in the starlight.</p> <p>Nate looked back. "Samuel knew he wasn't going to be able to stay in society. He figured that they'd eventually see him still alive and start questioning it, so he decided that he'd have to disappear after a while. He faked his death once, but changed his mind - he decided it was too early and he could stay for a little longer. He wasn't very fond of mankind, but he liked the attention. Most of the time, anyway.</p> <p>"His daughter and then his wife dying almost did him in though. He didn't stay in society much longer after that. He eventually came out here to spend time talking to me and thinking about pulling the lever. A few months ago he told me he'd had enough. It was his time."</p> <p>"And then he just died?" asked Jack.</p> <p>Nate shook his head a little. "He made his fourth request, Jack. There's only one thing you can ask for the fourth request. The last bite.</p> <p>After a bit Nate continued, "He told me that he was tired, that it was his time. He reassured me that someone new would show up soon, like they always had.</p> <p>After another pause, Nate finished, "Samuel's body disappeared off the stone with the sunrise."</p> <p>Jack lay back down and looked at the sky, leaving Nate alone with his memories. It was a long time until Jack's breathing evened out into sleep.</p> <p>Jack woke with the sunrise the next morning. He was a little chilled with the morning desert air, but overall was feeling pretty good. Well, except that his stomach was grumbling and he wasn't willing to eat raw desert rat.</p> <p>So, after getting directions to town from Nate, making sure he knew how to get back, and reassuring Nate that he'd be back soon, Jack started the long walk back to town. With his new health and Nate's good directions, he made it back easily.</p> <p>Jack caught a bus back to the city, and showed up for work the next day, little worse for the wear and with a story about getting lost in the desert and walking back out. Within a couple of days Jack had talked a friend with a tow truck into going back out into the desert with him to fetch the SUV. They found it after a couple of hours of searching and towed it back without incident. Jack was careful not to even look in the direction of Nate's lever, though their path back didn't come within sight of it.</p> <p>Before the next weekend, Jack had gone to a couple of stores, including a book store, and had gotten his SUV back from the mechanic, with a warning to avoid any more joyriding in the desert. On Saturday, Jack headed back to see Nate.</p> <p>Jack parked a little way out of the small town near Nate, loaded up his new backpack with camping gear and the things he was bringing for Nate, and then started walking. He figured that walking would leave the least trail, and he knew that while not many people camped in the desert, it wasn't unheard of, and shouldn't really raise suspicions.</p> <p>Jack had brought more books for Nate - recent books, magazines, newspapers. Some things that would catch Nate up with what was happening in the world, others that were just good books to read. He spent the weekend with Nate, and then headed out again, telling Nate that he'd be back again soon, but that he had things to do first.</p> <p>Over four months later Jack was back to see Nate again. This time he brought a laptop with him - a specially modified laptop. It had a solar recharger, special filters and seals to keep out the sand, a satellite link-up, and a special keyboard and joystick that Jack hoped that a fifteen-foot rattlesnake would be able to use. And, it had been hacked to not give out its location to the satellite.</p> <p>After that Jack could e-mail Nate to keep in touch, but still visited him fairly regularly - at least once or twice a year.</p> <p>After the first year, Jack quit his job. For some reason, with the wisdom he'd been given, and the knowledge that he could live for over 150 years, working in a nine to five job for someone else didn't seem that worthwhile any more. Jack went back to school.</p> <p>Eventually, Jack started writing. Perhaps because of the wisdom, or perhaps because of his new perspective, he wrote well. People liked what he wrote, and he became well known for it. After a time, Jack bought an RV and started traveling around the country for book signings and readings.</p> <p>But, he still remembered to drop by and visit Nate occasionally.</p> <p>On one of the visits Nate seemed quieter than usual. Not that Nate had been a fountain of joy lately. Jack's best guess was that Nate was still missing Samuel, and though Jack had tried, he still hadn't been able to replace Samuel in Nate's eyes. Nate had been getting quieter each visit. But on this visit Nate didn't even speak when Jack walked up to the lever. He nodded at Jack, and then went back to staring into the desert. Jack, respecting Nate's silence, sat down and waited.</p> <p>After a few minutes, Nate spoke. "Jack, I have someone to introduce you to."</p> <p>Jack looked surprised. "Someone to introduce me to?" Jack looked around, and then looked carefully back at Nate. "This something to do with the Big Guy?</p> <p>"No, no," replied Nate. "This is more personal. I want you to meet my son." Nate looked over at the nearest sand dune. "Sammy!"</p> <p>Jack watched as a four foot long desert rattlesnake crawled from behind the dune and up to the stone base of the lever.</p> <p>"Yo, Jack," said the new, much smaller snake.</p> <p>"Yo, Sammy" replied Jack. Jack looked at Nate. "Named after Samuel, I assume?"</p> <p>Nate nodded. "Jack, I've got a favor to ask you. Could you show Sammy around for me?" Nate unwrapped himself from the lever and slithered over to the edge of the stone and looked across the sands. "When Samuel first told me about the world, and brought me books and pictures, I wished that I could go see it. I wanted to see the great forests, the canyons, the cities, even the other deserts, to see if they felt and smelled the same. I want my son to have that chance - to see the world. Before he becomes bound here like I have been.</p> <p>"He's seen it in pictures, over the computer that you brought me. But I hear that it's not the same. That being there is different. I want him to have that. Think you can do that for me, Jack?"</p> <p>Jack nodded. This was obviously very important to Nate, so Jack didn't even joke about taking a talking rattlesnake out to see the world. "Yeah, I can do that for you, Nate. Is that all you need?" Jack could sense that was something more.</p> <p>Nate looked at Sammy. Sammy looked back at Nate for a second and then said, "Oh, yeah. Ummm, I've gotta go pack. Back in a little bit Jack. Nice to meet ya!" Sammy slithered back over the dune and out of sight.</p> <p>Nate watched Sammy disappear and then looked back at Jack. "Jack, this is my first son. My first offspring through all the years. You don't even want to know what it took for me to find a mate." Nate grinned to himself. "But anyway, I had a son for a reason. I'm tired. I'm ready for it to be over. I needed a replacement."</p> <p>Jack considered this for a minute. "So, you're ready to come see the world, and you wanted him to watch the lever while you were gone?"</p> <p>Nate shook his head. "No, Jack - you're a better guesser than that. You've already figured out - I'm bound here - there's only one way for me to leave here. And I'm ready. It's my time to die."</p> <p>Jack looked more closely at Nate. He could tell Nate had thought about this - probably for quite a while. Jack had trouble imagining what it would be like to be as old as Nate, but Jack could already tell that in another hundred or two hundred years, he might be getting tired of life himself. Jack could understand Samuel's decision, and now Nate's. So, all Jack said was, "What do you want me to do?"</p> <p>Nate nodded. "Thanks, Jack. I only want two things. One - show Sammy around the world - let him get his fill of it, until he's ready to come back here and take over. Two - give me the fourth request.</p> <p>"I can't just decide to die, not any more than you can. I won't even die of old age like you eventually will, even though it'll be a long time from now. I need to be killed. Once Sammy is back here, ready to take over, I'll be able to die. And I need you to kill me.</p> <p>"I've even thought about how. Poisons and other drugs won't work on me. And I've seen pictures of snakes that were shot - some of them live for days, so that's out too. So, I want you to bring back a sword.</p> <p>Nate turned away to look back to the dune that Sammy had gone behind. "I'd say an axe, but that's somewhat undignified - putting my head on the ground or a chopping block like that. No, I like a sword. A time-honored way of going out. A dignified way to die. And, most importantly, it should work, even on me.</p> <p>"You willing to do that for me, Jack?" Nate turned back to look at Jack.</p> <p>"Yeah, Nate," replied Jack solemnly, "I think I can handle that."</p> <p>Nate nodded. "Good!" He turned back toward the dune and shouted, "Sammy! Jack's about ready to leave!" Then quietly, "Thanks, Jack."</p> <p>Jack didn't have anything to say to that, so he waited for Sammy to make it back to the lever, nodded to him, nodded a final time to Nate, and then headed into the desert with Sammy following.</p> <p>Over the next several years Sammy and Jack kept in touch with Nate through e-mail as they went about their adventures. They made a goal of visiting every country in the world, and did a respectable job of it. Sammy had a natural gift for languages, as Jack expected he would, and even ended up acting as a translator for Jack in a few of the countries. Jack managed to keep the talking rattlesnake hidden, even so, and by the time they were nearing the end of their tour of countries, Sammy had only been spotted a few times. While there were several people that had seen enough to startle them greatly, nobody had enough evidence to prove anything, and while a few wild rumors and stories followed Jack and Sammy around, nothing ever hit the newspapers or the public in general.</p> <p>When they finished the tour of countries, Jack suggested that they try some undersea diving. They did. And spelunking. They did that too. Sammy finally drew the line at visiting Antarctica. He'd come to realize that Jack was stalling. After talking to his Dad about it over e-mail, he figured out that Jack probably didn't want to have to kill Nate. Nate told Sammy that humans could be squeamish about killing friends and acquaintances.</p> <p>So, Sammy eventually put his tail down (as he didn't have a foot) and told Jack that it was time - he was ready to go back and take up his duties from his dad. Jack, delayed it a little more by insisting that they go back to Japan and buy an appropriate sword. He even stretched it a little more by getting lessons in how to use the sword. But, eventually, he'd learned as much as he was likely to without dedicating his life to it, and was definitely competent enough to take the head off of a snake. It was time to head back and see Nate.</p> <p>When they got back to the US, Jack got the old RV out of storage where he and Sammy had left it after their tour of the fifty states, he loaded up Sammy and the sword, and they headed for the desert.</p> <p>When they got to the small town that Jack had been trying to find those years ago when he'd met Nate, Jack was in a funk. He didn't really feel like walking all of the way out there. Not only that, but he'd forgotten to figure the travel time correctly, and it was late afternoon. They'd either have to spend the night in town and walk out tomorrow, or walk in the dark.</p> <p>As Jack was afraid that if he waited one more night he might lose his resolve, he decided that he'd go ahead and drive the RV out there. It was only going to be this once, and Jack would go back and cover the tracks afterward. They ought to be able to make it out there by nightfall if they drove, and then they could get it over tonight.</p> <p>Jack told Sammy to e-mail Nate that they were coming as he drove out of sight of the town on the road. They then pulled off the road and headed out into the desert.</p> <p>Everything went well, until they got to the sand dunes. Jack had been nursing the RV along the whole time, over the rocks, through the creek beds, revving the engine the few times they almost got stuck. When they came to the dunes, Jack didn't really think about it, he just downshifted and headed up the first one. By the third dune, Jack started to regret that he'd decided to try driving on the sand. The RV was fishtailling and losing traction. Jack was having to work it up each dune slowly and was trying to keep from losing control each time they came over the top and slid down the other side. Sammy had come up to sit in the passenger seat, coiled up and laughing at Jack's driving.</p> <p>As they came over the top of the fourth dune, the biggest one yet, Jack saw that this was the final dune - the stone, the lever, and somewhere Nate, waited below. Jack put on the brakes, but he'd gone a little too far. The RV started slipping down the other side.</p> <p>Jack tried turning the wheel, but he didn't have enough traction. He pumped the brakes - no response. They started sliding down the hill, faster and faster.</p> <p>Jack felt a shock go through him as he suddenly realized that they were heading for the lever. He looked down - the RV was directly on course for it. If Jack didn't do something, the RV would hit it. He was about to end humanity.</p> <p>Jack steered more frantically, trying to get traction. It still wasn't working. The dune was too steep, and the sand too loose. In a split second, Jack realized that his only chance would be once he hit the stone around the lever - he should have traction on the stone for just a second before he hit the lever - he wouldn't have time to stop, but he should be able to steer away.</p> <p>Jack took a better grip on the steering wheel and tried to turn the RV a little bit - every little bit would help. He'd have to time his turn just right.</p> <p>The RV got to the bottom of the dune, sliding at an amazing speed in the sand. Just before they reached the stone Jack looked across it to check that they were still heading for the lever. They were. But Jack noticed something else that he hadn't seen from the top of the dune. Nate wasn't wrapped around the lever. He was off to the side of the lever, but still on the stone, waiting for them. The problem was, he was waiting on the same side of the lever that Jack had picked to steer towards to avoid the lever. The RV was already starting to drift that way a little in its mad rush across the sand and there was no way that Jack was going to be able to go around the lever to the other side.</p> <p>Jack had an instant of realization. He was either going to have to hit the lever, or run over Nate. He glanced over at Sammy and saw that Sammy realized the same thing.</p> <p>Jack took a firmer grip on the steering wheel as the RV ran up on the stone. Shouting to Sammy as he pulled the steering wheel, "Better Nate than lever!", he ran over the snake.</p> <p>THE END</p> Making a Bloghttps://fireis.dev/blog/making-a-blog/https://fireis.dev/blog/making-a-blog/But why?Wed, 24 Apr 2024 00:00:00 GMT<p>I wanted to make a blog, so I did!</p> <p>Previously, I tried making <a href="https://fireisgood.github.io/astro-testing-site/">a</a> <a href="https://fireisgood.github.io/learning-svelte-site/">few</a> <a href="https://fireiswebsite.netlify.app/">websites</a> <a href="https://fireisgood.github.io/fancy-text/">for</a> <a href="https://fireisgood.github.io/astro-testing/">testing</a> <a href="https://fireisgood.github.io/fish-quiz/">things</a>, but none of them had quite the right vibe and ease of use to be an actual blog. After checking out the Astro blog template, I found that it did a ton of the back end stuff I was dreading. It had the basic <code>content</code> setup from the new version of Astro as well as some nice type checked frontmatter I hadn't set up on my previous website setup attempt. There was also the basic markdown blog format which I would have had to reinvent myself.</p> <h2>Setting It Up</h2> <p>All that being said, I ran into a differences in style preferences with the version out of the box. The template used some random global style sheet that I didn't really feel was clean enough and the layout was a bit off from what I wanted. To fix, this I ripped everything out and started with a base of <a href="https://picocss.com/">Pico CSS</a>—my favorite CSS mini-framework.</p> <p>From there, I was able to relatively easily just go wild with my styles knowing I had clean and semantic defaults to rely on. As usual with my website styling, I threw on the basic max width and card-ish setup. This website has a <code>960px</code> max width, though I have used <code>1080px</code> or other random widths for other sites. I also decided to try out a newer trick with the body to force the footer to stick to the bottom of the screen.</p> <h2>Suffering</h2> <p>The unavoidable problem with CSS is that you will <em>always</em> find some new jank to cut yourself on. Today's lesson was on the <code>display: grid</code> property and its interaction with specifically the <code>&lt;pre&gt;</code> block. When I was trying to check on the included markdown mini tutorial, I found that the block size code blocks were overflowing—but not where I expected! For some strange reason, it was pushing the <code>&lt;body&gt;</code> to be larger than the window when its parent clearly had <code>overflow-x: auto</code> set!</p> <p>Oh dear, oh my!</p> <p>After some quick searching, I found a <a href="https://css-tricks.com/preventing-a-grid-blowout/">CSS Tricks article</a> with the solution. As it turned out, the issue was something to do with the fact that the default for each grid direction said that the minimum size should be <code>auto</code>, so content inside would poke out of the viewport. The fix was some evil hack using <code>minmax()</code> to tell it that it can go down to 0 pixels wide if it needs to.</p> <p>CSS never fails to get you...</p> <pre><code>body { display: grid; grid-template-rows: auto 1fr auto; grid-template-columns: minmax(0, 1fr); /* Evil grid bug */ } </code></pre> <h2>We Are So Back</h2> <p>After that, it wasn't actually that difficult to clean up the styles and other fun stuff. I added in a theme switcher that I developed while working on re-styling <a href="https://radian628.github.io/good-questions/">Good Questions</a>. It worked pretty well, but after I added View Transitions, it broke. I had to set up some event listeners and timeouts in a slightly janky way to get it back up and working cleanly.</p> <p><img src="../../images/view-transition-example.gif" alt="View Transition example" /></p> <p>After setting this up, I spent a while working on cleaning up the UI and adding more comfy features like breadcrumbs and fixing up the slightly hacky title setup I had.</p> <h2>Reflection</h2> <p>Overall it wasn't too hard to set up. I would probably recommend this to other mid-level web developers. For a very basic personal site to new web developers, I would instead recommend learning the basics of setting up your own basic website starting from the Visual Studio Code emmet preset you get from <code>!</code>. It's a decent place to start learning how to write semantic things and it also just makes me happy to not deal with the feature creep of a framework.</p> Static Sites Really Fasthttps://fireis.dev/blog/static-sites-really-fast/https://fireis.dev/blog/static-sites-really-fast/Making a static site really fastWed, 18 Dec 2024 00:00:00 GMT<p>A static website is a website whose contents are basic HTML, CSS, and JS—hand-written or generated from more code. These files can then be served over many services directly without having to run a special type of server—they just need to be able to serve files. This makes them the easiest way to host websites as long as the content on the site doesn't change constantly.</p> <p>For learning web development, I believe making a site in this way is one of the fastest ways to get something you've made out there.</p> <p>To create a static website, you first need to make your website's files and then host them somewhere online.</p> <h2>Making the Website</h2> <p>To start out, you don't really need a framework or otherwise—Just some basic HTML. We start out in our project's directory with a file called <code>index.html</code> so it will be loaded to the base path of the URL.</p> <pre><code>(empty file right now) </code></pre> <p>If you're using a modern code editor with completions from <a href="https://emmet.io">Emmet</a> you can get the basic outline with a code snippet expanded from <code>html:5</code>. You should also have a formatter on hand for this process to keep things tidy. I use <a href="https://prettier.io">Prettier</a> as it's widely used and doesn't need configuration to work well.</p> <p>Below is the snippet provided by Emmet and cleaned up by Prettier:</p> <pre><code>&lt;!doctype html&gt; &lt;html lang="en"&gt; &lt;head&gt; &lt;meta charset="UTF-8" /&gt; &lt;meta name="viewport" content="width=device-width, initial-scale=1.0" /&gt; &lt;title&gt;Document&lt;/title&gt; &lt;/head&gt; &lt;body&gt;&lt;/body&gt; &lt;/html&gt; </code></pre> <p>With this template, you can add some semantic HTML and some placeholder content. I usually add in Pico CSS just to get things looking good to start, so I've added the classless basic version in the <code>&lt;head&gt;</code>.</p> <p>&lt;!-- use default prettier format as an example --&gt; &lt;!-- prettier-ignore --&gt;</p> <pre><code>&lt;!doctype html&gt; &lt;html lang="en"&gt; &lt;head&gt; &lt;meta charset="UTF-8" /&gt; &lt;meta name="viewport" content="width=device-width, initial-scale=1.0" /&gt; &lt;title&gt;I'm the best&lt;/title&gt; &lt;link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@picocss/pico@2/css/pico.classless.min.css" /&gt; &lt;/head&gt; &lt;body&gt; &lt;main&gt; &lt;article&gt; &lt;h1&gt;I'm the best&lt;/h1&gt; &lt;p&gt;It's simply well known&lt;/p&gt; &lt;/article&gt; &lt;/main&gt; &lt;footer&gt; &lt;p&gt;Made by me, the best&lt;/p&gt; &lt;/footer&gt; &lt;/body&gt; &lt;/html&gt; </code></pre> <p>Now you're ready to host it online!</p> <h2>Hosting it Online</h2> <p>Hosting a static website can be done through many sources for free or through paid services to get servers for you. Unfortunately for our objective, these aren't very fast to set up and you're unlikely to have an account on some web hosting service if you're making a website for the first time.</p> <p>As we want to get this hosted fast, we can use something very fast or very widespread in the forms of Surge or GitHub Pages. They both have a few trade-offs as listed here for brevity:</p> <ul> <li><a href="https://surge.sh">Surge</a> <ul> <li>Just need an email</li> <li>All from the command line</li> <li>Must manually republish</li> <li>Default URL is <code>[custom-name-here].surge.sh</code></li> </ul> </li> <li><a href="https://pages.github.com">GitHub Pages</a> <ul> <li>Requires a GitHub account (you probably have one)</li> <li>Additional step to configure the repository on GitHub</li> <li>Automatically republishes on Git push</li> <li>Default URL is <code>[your-github-username].github.io</code>; the base domain or a subdomain of it. <ul> <li>The repository <code>test/cool-website</code> will be hosted at <code>test.github.io/cool-website</code></li> <li>The repository <code>test/test.github.io</code> will be hosted at <code>test.github.io</code></li> </ul> </li> </ul> </li> </ul> <p>For the main section of this guide, we will use Surge to just get the site up fast. Afterwards, we will go back and host over GitHub Pages for open source sites you want to redeploy as you commit updates.</p> <h3>Hosting over Surge</h3> <p>To host over surge, you need to use the Surge CLI. Using <a href="https://www.npmjs.com">NPM</a> you can either install it globally or run it via <code>npx</code>.</p> <pre><code># Install globally npm install --global surge # Run surge # Run directly npx surge </code></pre> <p>With either of these methods, run the Surge CLI in your project's directory, then follow the prompts. You did it! Whenever you want to update your website, just run your Surge command and use the same URL.</p> <p>You can see an example website at <a href="https://unadvised-chance.surge.sh">unadvised-chance.surge.sh</a> and its extremely minimal code at my <a href="https://github.com/FireIsGood/surge-static-article">GitHub repository</a>.</p> <p>For a more detailed guide, you can check out the <a href="https://surge.sh/help/getting-started-with-surge">Surge Docs</a> on this topic.</p> <h3>Hosting over GitHub Pages</h3> <p>To host over GitHub Pages, you need a GitHub account and Git. To use GitHub pages without the 'Pro' subscription, your repository will need to be public. Additionally, the default for using a repository that isn't named in the format of <code>[your-github-username].github.io</code> will be deployed as a subdomain under that URL.</p> <p>To start, initialize a Git repository in your project folder and commit everything.</p> <pre><code>git init git add -a git commit -m "Initial Commit" </code></pre> <p>Next, <a href="https://github.com/new">create a new repository on GitHub</a>. I would recommend to not add anything as it will show you how to push your files if you don't have files in the repository.</p> <p>If you added any options, you will have to manually type:</p> <pre><code>git remote add origin https://github.com/[your-username]/[repository-name].git git branch -M main git push -u origin main </code></pre> <p>Now, navigate to the GitHub repository online and go to the <strong>Settings</strong> tab and then <strong>Code and automation -&gt; Pages</strong>. Change the "Source" option to GitHub Actions and click "Configure" on the <strong>Static HTML</strong> option. Click <strong>Commit Changes</strong>, rename the commit if you want, and click <strong>Confirm</strong>.</p> <p><img src="../../images/gh-pages-actions.png" alt="Setting up the GitHub Pages workflow" /></p> <p>This adds a file at <code>.github/workflows/static.yml</code> which will redeploy your site whenever changes are pushed to main. If you ever need to change anything about this, you can find it in that file. Your site should now be up within a few seconds!</p> <h4>Final Touches</h4> <p>For some final touches, you can make the GitHub page link directly to your new site instead of having users find it under Deployments. To do this, navigate to the top right gear icon to open the settings.</p> <p><img src="../../images/gh-pages-menu-cog.png" alt="Opening repository settings" /></p> <p>Then, check the <strong>Use your GitHub Pages website</strong>. While you're there, you can also uncheck the <strong>Releases</strong> and <strong>Packages</strong> options to clean up the side bar.</p> <p><img src="../../images/gh-pages-repo-settings.png" alt="Changing repository settings" /></p> <p>After you save your changes, the link to your site should appear under the About header.</p> <p><img src="../../images/gh-pages-about-after.png" alt="Fixed About section" /></p> <p>Whenever you want to update your website, just push local Git changes to your main branch. As with the initial deployment, changes should appear live on the site within seconds!</p> <p>You can see my example at <a href="https://fireisgood.github.io/static-site-example/">fireisgood.github.io/static-site-example</a> and its moderately minimal code at my <a href="https://github.com/FireIsGood/static-site-example">GitHub repository</a>.</p> <p>For a more detailed guide, you can check out the <a href="https://docs.github.com/en/pages/quickstart">GitHub Pages Docs</a> on this topic.</p> <h2>Conclusion</h2> <p>It's really that simple.</p> <p>If you want to continue refining your site by adding a custom domain or a better site in general, find some other article, I'm not going to explain it here.</p> <h3>Further Research</h3> <p>There are other hosts such as Netlify, Vercel, or Digital Ocean with nice free tiers for static hosting. For more information on those, you can check out <a href="https://free-for.dev/#/?id=web-hosting">Free For Dev page on Web Hosting</a>.</p> <p>You could also run your static site on a Virtual Private Server service or host it yourself if you wanted more control on the backend. Services like <a href="https://www.hostinger.com/vps-hosting">Hostinger</a>, <a href="https://www.digitalocean.com/pricing">Digital Ocean</a>, and many others can be found for this purpose.</p> Making C Not Suck in Visual Studio Codehttps://fireis.dev/blog/making-c-not-suck/https://fireis.dev/blog/making-c-not-suck/The weakness of defaultsSun, 01 Dec 2024 00:00:00 GMT<p>Visual Studio Code has been a pain to me for my entire coexistence with it. While I eventually moved to the greener pastures of customization at Neovim, I have seen enough of the same fixes that I thought I ought to share how I made my time writing in C/C++ less agonizing.</p> <p>Most of these troubles come from the default that Visual Studio Code provides.</p> <h2>The Defaults</h2> <p>The default experience for new users editing C/C++ code in Visual Studio Code is questionable. When you first open up a C/C++ anywhere in the editor, Visual Studio Code sends you a notification telling you to get an extension called the <strong>C/C++ Extension Pack</strong>.</p> <p><img src="../../images/base-c-extension-notification.png" alt="Visual Studio Code notification" /></p> <p>Surely this is exactly what you need to have a fast and clean editing experience, right? Let's check!</p> <p>This pack installs:</p> <ul> <li><a href="https://marketplace.visualstudio.com/items?itemName=ms-vscode.cpptools-extension-pack">C/C++ Extension Pack</a> <ul> <li><a href="https://marketplace.visualstudio.com/items?itemName=ms-vscode.cpptools">C/C++</a> (language server, slow)</li> <li><a href="https://marketplace.visualstudio.com/items?itemName=ms-vscode.cpptools-themes">C/C++ Themes</a> (redundant color schemes)</li> <li><a href="https://marketplace.visualstudio.com/items?itemName=twxs.cmake">CMake</a> (tools for CMake software, not used by all new developers)</li> <li><a href="https://marketplace.visualstudio.com/items?itemName=ms-vscode.cmake-tools">CMake Tools</a> (see previous note)</li> </ul> </li> </ul> <p>Looking at these tools, we can note that you only really want <em>one</em> of them—the <strong>C/C++ Extension</strong>. The other extensions provide things that are most likely useless to the average developer trying out C. The themes are essentially just the default dark theme with <em>very slightly</em> altered code colors. The CMake related plugins are only useful if you wish to specifically use CMake in your project.</p> <p>The C/C++ Extension itself is a bit dodgy; the provided error highlighting takes relative ages to tell you once you've messed up and leads to constantly stopping to wait for the extension to wake up and do its job.</p> <p><img src="../../images/base-c-lsp.gif" alt="Error highlighting under base plugins" /></p> <p>In addition to this, the auto-completion it provides are lackluster. When you write in a valid function and try to complete it, the extension just writes out the rest of the name—not completing the arguments.</p> <p><img src="../../images/base-c-snippets.gif" alt="Error highlighting under base snippets" /></p> <p>In addition to these annoyingly mediocre features, it doesn't even make it clear that the C/C++ extension provides a formatter or how to use it.</p> <p><em>(It's <code>ctrl+shift+i</code>, if you're wondering)</em></p> <p>The formatter works alright, though the method to customize it is <a href="https://code.visualstudio.com/docs/cpp/cpp-ide#_code-formatting">buried in the documentation</a>.</p> <h2>Improving the Setup</h2> <p>We can fix it through a few changes:</p> <ul> <li>Uninstall the <strong>C/C++ Extension Pack</strong></li> <li>Get <a href="https://marketplace.visualstudio.com/items?itemName=llvm-vs-code-extensions.vscode-clangd">clangd</a> (language server, fast) <ul> <li>Enable or disable inlay hints</li> </ul> </li> <li>Get <a href="https://marketplace.visualstudio.com/items?itemName=hars.CppSnippets">C/C++ Snippets</a> (auto-complete for things like <code>if</code> or <code>for</code> optional)</li> <li>Get <a href="https://marketplace.visualstudio.com/items?itemName=xaver.clang-format">Clang-Format</a> (formatter, customizable) <ul> <li>Enable <code>Format On Save</code></li> </ul> </li> <li>Set the <code>clang-format.style</code> option to what you want</li> </ul> <p>The first step is to just uninstall the <strong>C/C++ Extension Pack</strong>. This will uninstall all of the tools noted above in one step. You won't need them after the next steps.</p> <h3>Clangd</h3> <p>You can obtain the clangd extension via the extensions tab under <code>llvm-vs-code-extensions.vscode-clangd</code> or with the following command in the Quick Open (<code>Ctrl+p</code>) menu:</p> <pre><code>ext install llvm-vs-code-extensions.vscode-clangd </code></pre> <p>If you did not follow the step above to uninstall the <strong>C/C++ Extension Pack</strong>, you will receive a notification at the bottom right telling you to disable IntelliSense the C/C++ Extension. Do that.</p> <p>After the plugin is installed, you will note that the error highlighting works almost instantly now.</p> <p><img src="../../images/clangd-c-lsp.gif" alt="Error highlighting under Clangd" /></p> <p>You may also note that functions have ghost text within them noting function parameter names. This is called Inlay Hints and can be toggled through the Command Palette (<code>Ctrl+Shift+C</code>) command <strong>clangd: Toggle inlay hints</strong>.</p> <p><img src="../../images/inlay-hints.gif" alt="Toggling inlay hints" /></p> <p>These two options are generally all you need to know about the very basics of using clangd.</p> <h3>C/C++ Snippets</h3> <p>You can obtain the C/C++ Snippets extension via the extensions tab under <code>hars.CppSnippets</code> or with the following command in the Quick Open (<code>Ctrl+p</code>) menu:</p> <pre><code>ext install hars.CppSnippets </code></pre> <p>Now if you type <code>printf</code> or other functions in a C file, you will get useful completions!</p> <p><img src="../../images/clangd-c-snippets.gif" alt="Error highlighting under new snippets" /></p> <p>The ones provided by this plugin include more general and filled out versions of control flow statements like <code>forr</code>, or <code>switch</code>.</p> <h3>Clang-Format</h3> <p>You can obtain the Clang-Format extension via the extensions tab under <code>xaver.clang-format</code> or with the following command in the Quick Open (<code>Ctrl+p</code>) menu:</p> <pre><code>ext install xaver.clang-format </code></pre> <p>I was checking the reviews on this plugin while researching this and many mention that they existing <code>C/C++</code> extension has the same functionality, but that requires its IntelliSense to be enabled which breaks things when combined with Clangd.</p> <p>After installing, you should now be able to format your code. By default, this can only be done manually with either the Command Palette (<code>Ctrl+Shift+C</code>) command <strong>Format Document</strong> or through its keybind of <code>Ctrl+Shift+i</code>.</p> <p><img src="../../images/clang-format-command.gif" alt="Clang-Format command" /></p> <p>If you wish to automatically format your document whenever you manually save with <code>Ctrl+S</code>, you can enable it through the setting <code>editor.formatOnSave</code> as changed in the settings menu accessed via <code>Ctrl+,</code>.</p> <h3>Customizing Formatting</h3> <p>By default, Clang-Format will find a <code>.clang-format</code> file to use as its formatting style. If you have a specific way you like to format all of your code more complex than the provided options of LLVM, Google, Chromium, Mozilla, or WebKit, you can specify it manually via JSON.</p> <p>To customize your formatting options, open up the settings menu and search for <code>clang-format.style</code>. The default is <code>file</code> which you can replace with a JSON string of the options you want as specified the <a href="https://clang.llvm.org/docs/ClangFormatStyleOptions.html">LLVM docs on Clang-Format</a>.</p> <p><img src="../../images/clang-format-setting.png" alt="clang-format.style in settings set to 'file'" /></p> <p>The following JSON strings <em>must</em> be provided as the <code>style</code> parameter of a given language. Using them under <code>Fallback Style</code> will not work and cause errors in the Output of your console.</p> <p>Here is a basic JSON string setup:</p> <pre><code>{ BasedOnStyle: Google, BreakBeforeBraces: 'Attach', IndentWidth: 4, TabWidth: 4, ColumnLimit: 89, MaxEmptyLinesToKeep: 2, AlignTrailingComments: true, } </code></pre> <p>The value of <code>BreakBeforeBraces</code> should be <code>'Attach'</code> for K&amp;R style and <code>'Allman'</code> or unset for Allman style. The default for Google is <code>'Attach'</code>, but if you wish to use another style it is important to have.</p> <p>Here is what they look like:</p> <pre><code>// K&amp;R ('Attach') while (x == y) { foo(); bar(); } // Allman ('Allman') while (x == y) { foo(); bar(); } </code></pre> <p>Decide on your style, then copy the JSON into the <code>clang-format.style</code> setting. Whitespace is ignored, though make sure that you have commas between every property and that single quotes are used throughout.</p> <p>Here's the one from before on a single line:</p> <p>&lt;!-- markdownlint-disable MD013 --&gt;</p> <pre><code>{ BasedOnStyle: Google, BreakBeforeBraces: 'Attach', IndentWidth: 4, TabWidth: 4, ColumnLimit: 89, MaxEmptyLinesToKeep: 2, AlignTrailingComments: true,} </code></pre> <p>&lt;!-- markdownlint-enable MD013 --&gt;</p> <p><img src="../../images/clang-format-setting-set.png" alt="clang-format.style in settings set to a JSON string" /></p> <p>For the full documentation see the <a href="https://clang.llvm.org/docs/ClangFormatStyleOptions.html">LLVM docs on Clang-Format</a> as mentioned before.</p> <h2>Possible Issues</h2> <p>The clangd extension doesn't provide formatting of its own leading to the use of the Clang-Format plugin. This is an issue as that plugin doesn't allow you to use a local file by default while still having your own formatting as a fallback. The default C/C++ Extensions allows for this but has poor performance which I arbitrarily decided was worth the trade-off.</p> <p>I could also be missing some obvious method to make the default plugin faster, but at that point it's on the developers for hiding a "make it work better" option when they provide the extension pack as the default.</p> <h2>Conclusion</h2> <p>To be honest, I don't like C. If you have the chance, program in anything else; Rust, Zig, JavaScript(??), anything but the horrors of C. If you must, I give you my greatest condolences and I hope prior advice can ease your pains if only by a little.</p>