small pixel drawing of a pufferfish existentialcrisis.sh

Make some minor wording adjustments, h3h3h3h3
Jes Olson j3s@c3f.net
Sat, 14 May 2022 15:20:40 -0500
commit

16bea0d0d3a2b20bd268f99cdb28b479b09efb4c

parent

acc7558166b32f57287fc21db57dc6ac6921040f

4 files changed, 17 insertions(+), 12 deletions(-)

jump to
M main.gomain.go

@@ -167,7 +167,12 @@ if peopleWhoLoveYouDearly < 0 {

peopleWhoLoveYouDearly = 0 } - text := fmt.Sprintf("in the year %d you are %s. %s %d. %d people %s, and %d of them %s you dearly.", predictionYear, status, firstTense, predictionAge, peopleWhoKnowYou, secondTense, peopleWhoLoveYouDearly, thirdTense) + var text string + if peopleWhoKnowYou == 0 && peopleWhoLoveYouDearly == 0 { + text = fmt.Sprintf("in the year %d you are %s. nobody remembers you.", predictionYear, status) + } else { + text = fmt.Sprintf("in the year %d you are %s. %s %d. %d people %s, and %d of them %s you dearly.", predictionYear, status, firstTense, predictionAge, peopleWhoKnowYou, secondTense, peopleWhoLoveYouDearly, thirdTense) + } fmt.Fprintf(w, text) }
M templates/features.htmltemplates/features.html

@@ -1,4 +1,4 @@

{{define "title"}}existentialcrisis.sh/features{{end}} {{define "body"}} -<p>everyone will die, and everything will end. ultimately our features don't matter. +<p>ultimately our features don't matter. {{end}}
M templates/index.htmltemplates/index.html

@@ -3,21 +3,21 @@ {{define "body"}}

<p>existentialcrisis.sh is a powerful API toolkit that you may use if you'd like to have an existential crisis.</p> <p>The below tools should all be very helpful in triggering an existential crisis. They are used inadvertently by the author every day.</p> <hr> -<h2>receive a quote that may induce existential dread</h2> +<h3>receive a quote that may induce existential dread</h3> <pre>GET <a href="/api/v1/crisis/quote">/api/v1/crisis/quote</a></pre> <hr> -<h2>estimate the percentage of life you have lived</h2> -<pre>GET <a href="/api/v1/crisis/percentage?age=28">/api/v1/crisis/percentage?age=X</a> +<h3>estimate the percentage of life you have lived</h3> +<pre>GET <a href="/api/v1/crisis/percentage?age=29">/api/v1/crisis/percentage?age=X</a> X = your age (1-100)</pre> <hr> -<h2>estimate the number of saturdays remaining</h2> -<pre>GET <a href="/api/v1/crisis/saturday?age=28">/api/v1/crisis/saturday?age=X</a> +<h3>estimate the number of saturdays remaining</h3> +<pre>GET <a href="/api/v1/crisis/saturday?age=29">/api/v1/crisis/saturday?age=X</a> X = your age (1-100)</pre> <hr> -<h2>estimate the number of people who will remember you in a given number of years</h2> -<pre>GET <a href="/api/v1/crisis/remember?age=28&years=100">/api/v1/crisis/remember?age=X&years=Y</a> +<h3>estimate the number of people who will remember you in a given number of years</h3> +<pre>GET <a href="/api/v1/crisis/remember?age=29&years=100">/api/v1/crisis/remember?age=X&years=Y</a> X = your age (1-100) Y = number of years from now (1-1000)</pre> <hr> -<sub>❤ made with love and sadness by j3s</sub> -{{end}}+<sub>❤ made with love and sadness by <a href="https://j3s.sh">j3s</a></sub> +{{end}}
M templates/layout.htmltemplates/layout.html

@@ -19,7 +19,7 @@ <title>{{template "title"}}</title>

</head> <body> <h1><a href="/">💀</a> existentialcrisis.sh</h1> -<p><a href="/features.html">features</a> <a href="/pricing.html">pricing</a> + <p><a href="/features.html">features</a> <a href="/pricing.html">pricing</a></p> {{template "body"}} </body> </html>