diff --git a/README.md b/README.md index 1a90b44..ad4dc58 100644 --- a/README.md +++ b/README.md @@ -25,7 +25,7 @@ cd www Then in a web browser, navigate to `localhost:8080`. -## TODO +## TODO Items All goals are currently completed. diff --git a/cronjob.sh b/cronjob.sh new file mode 100755 index 0000000..0d8eb51 --- /dev/null +++ b/cronjob.sh @@ -0,0 +1,66 @@ +#!/usr/bin/env bash +# 2025-10-14 Hyperling +# Copied cronjob.sh from env-docker/Config/Hugo-Example/files/ to use for this +# project so that docker container can do periodic git pulls rather than having +# to reload /rebuild the container each time a release is pushed out. + +## Setup ## + +DIR="$(dirname -- "${BASH_SOURCE[0]}")" +PROG="$(basename -- "${BASH_SOURCE[0]}")" +cd $DIR +DIR="`pwd`" +NAME="'$PROG'" + +function log { + echo -e "`date` : $NAME - $1" +} + +function kill-project { + # Kill node.js which will complete run.sh and restart any Docker containers. + # This is more intended towards Development and Stage sites since Production + # will only see git changes when a pull request is manually completed. + log "Stopping continuous processes!" + pkill node +} + +function reload-project { + # Nothing to do, run.sh and main.js automatically uses the latest files. + log "Project reloaded successfully!" +} + +## Main ## + +# Pull any updates, and if the project is already up to date, exit successfully. +output="`git pull`" +git_status="$?" + +echo "$output" | grep -v "up to date" +grep_status="$?" + +log "Pull status is '$git_status', checking for changes is '$grep_status'." + +# Check whether the continuously running jobs have been updated. +echo "$output" | grep "main.js" +main_changed="$?" +echo "$output" | grep "run.sh" +run_changed="$?" + +# Determine where we've landed and whether we need to do anything. +if [[ $git_status != 0 ]]; then + log "*** ERROR: Git reported a failure! ***" + exit 1 +elif [[ $git_status == 0 && ($main_changed == 0 || $run_changed == 0) ]]; then + log "Either main ('$main_changed'), or run ('$run_changed') were changed!" + kill-project +elif [[ $git_status == 0 && $grep_status == 0 ]]; then + reload-project +elif [[ $git_status == 0 && $grep_status != 0 ]]; then + log "Nothing to do. '$output'" +else + log "*** WARNING: Unknown Situation ***" +fi + +## Success! ## + +exit 0 diff --git a/pages/about.php b/pages/about.php index 0781d5a..ee7c102 100755 --- a/pages/about.php +++ b/pages/about.php @@ -5,15 +5,18 @@ } include "helpers/body_open.php"; ?> -

Who Am I?

+ - + <<about.jpg>>
+ ';?>
-
+

Hi there! My name is Chad, I'm the primary content creator behind Hyperling and HyperVegan. Thank you for your interest! @@ -26,7 +29,6 @@ planted at least one fruit tree or had a small square foot garden. We would be in paradise!

-

Coding and videos aren't my only hobbies, I'm also big into health. I see it as humanity's most important asset and take a @@ -51,7 +53,6 @@

- +
+

My Profession

+
+
+
+

+ I'm a professional software engineer who's been playing with + Linux system administration from a young age. + Much of my career has focused on back-end / database systems + and optimizing workflows. + I feel that I specialize in building systems with "no sharp + edges", meaning that I test rigorously to ensure there aren't any + ways the user can hurt themselves or the system. + In my free time I enjoy learning new + languages and writing apps for Android. +

+ +
+
+ +
+

Obtainium Configuration

+
+ +
+
+ Automatic Import +

+ This JSON file will add all of my apps for you in its own + convenient group: +

+ +

+ Then if you only want to keep a subset of the apps you may either + mark the unwanted ones as Track Only or delete them from the app. +

+
+ +
+ Manual Imports +

+ If you decide to add the apps 1-by-1 based on the URLs in the + section below, here is how to show the correct version numbers: +

+
    +
  • Enable "Sort by only the last segment of the link".
  • +
  • + Set the "Version string extraction RegEx" field to: + [0-9\.]+[0-9]+ +
  • +
+

+ Otherwise, using "Take first link" ensures you get the + proper update but will show pseudo versions. +

+
+ + +
+ +
+

Android Apps

+
+ +
+ +
+ +
+ <<expense.png>> +
+ Recurring Expense Tracker +
+
+
+

+ Keep track of repeating expenses and + view projections of their effect on your finances. + First app written with Flutter. +

+

+ + [Source Code] + [APKs / Obtainium URL] +

+
+ +
+ +
+ <<tictactoe.png>> +
+ Tic-Tac-Toe +
+
+
+

+ Play against a friend or a range of AIs. + Written to practice Kotlin/Compose. +

+

+ + [Source Code] + [APKs / Obtainium URL] +

+
+ +
+ +
+ <<ctfu.png>> +
+ Carb Up! BETA +
+
+
+

+ Calculate cost-effective foods on a High Carb Low Fat lifestyle. +

+

+ + [Source Code] + [APKs / Obtainium URL] +

+ +
+ +
+ +
+ <<infinitetimer.png>> +
+ Infinite Timer +
+
+
+

+ Play a notification at your chosen interval. +

+

+ + [Source Code] + [APKs / Obtainium URL] +

+ +
+ +
+ +
+ <<t45mr.png>> +
+ 45 Minute Rule +
+
+
+

+ Determine a good bedtime for waking during light sleep. +

+

+ + [Source Code] + [APKs / Obtainium URL] +

+ +
+ +
+ +
+ <<hypergames.png>> +
+ HyperGames +
+
+
+

+ Started as a fun project for learning. + Playable but unfinished. +

+

+ + [Source Code] + [APKs / Obtainium URL] +

+ +
+
+ +
+

Other Programs

+
+
+
+

+ For a full list of software including my Ansible automation, + Docker setup, source code for this website, and other + fun/random toys, check out + My Projects. +

+
+
+ diff --git a/pages/books.php b/pages/books.php new file mode 100755 index 0000000..237fead --- /dev/null +++ b/pages/books.php @@ -0,0 +1,10 @@ +#!/usr/bin/php + + diff --git a/pages/contact.php b/pages/contact.php index a315c8e..1317650 100755 --- a/pages/contact.php +++ b/pages/contact.php @@ -5,21 +5,28 @@ } include "helpers/body_open.php"; ?> -

Contact

+ - + <<contact.jpg>>
+ ';?>
-
+

- Timely responses are not guarenteed, as I spend a majority of - my time offline and enjoy traveling in reception-free zones. + Timely responses are not guarenteed, as I spend a large amount of + time offline and enjoy traveling in reception-free zones.

+ +
+

Methods

+

@@ -42,7 +49,6 @@

- diff --git a/pages/diet.php b/pages/diet.php index c474611..93e0a24 100755 --- a/pages/diet.php +++ b/pages/diet.php @@ -5,12 +5,8 @@ } include "helpers/body_open.php"; ?> -

Current Diet

-
- Image TBD -
@@ -208,7 +204,6 @@
- diff --git a/pages/freedom.php b/pages/freedom.php index 4dd96af..58e5c2e 100755 --- a/pages/freedom.php +++ b/pages/freedom.php @@ -9,7 +9,6 @@ } include "helpers/body_open.php"; ?> -

Voluntary Sovereignty

@@ -59,16 +58,30 @@

Curious how I made it? Check out its Git repository:

- + + +

+ Here is the video it was announced in: +

+
- diff --git a/pages/health.php b/pages/health.php index 1b7bd41..e47b16d 100755 --- a/pages/health.php +++ b/pages/health.php @@ -3,13 +3,12 @@ Page to provide ways people can support me. --> -

My Health Protocol

@@ -109,7 +108,6 @@ - diff --git a/pages/helpers/advisory.php b/pages/helpers/advisory.php index 3b1499e..e349a49 100755 --- a/pages/helpers/advisory.php +++ b/pages/helpers/advisory.php @@ -1,12 +1,13 @@ #!/usr/bin/php +

-
-
-

Announcements

-
+
+

Latest Announcement

2025-09-28 @@ -16,3 +17,5 @@
+ '; +?> diff --git a/pages/helpers/banner.css b/pages/helpers/banner.css index fac7577..6ea6add 100644 --- a/pages/helpers/banner.css +++ b/pages/helpers/banner.css @@ -21,3 +21,16 @@ .banner-bottom { background-color: #33CC33; } + + .banner-image { + background-repeat: no-repeat; + + background-position: center, center; + height: 237px; /* 69*3[banner stripes] + 15*2[padding top+bot] */ + } + .banner-image01 { + background-image: url("/files/media/icons/home.jpg"); + } + .banner-image02 { + background-image: url("/files/media/icons/contact.jpg"); + } diff --git a/pages/helpers/banner.php b/pages/helpers/banner.php index e3855e0..510ae86 100755 --- a/pages/helpers/banner.php +++ b/pages/helpers/banner.php @@ -1,8 +1,32 @@ #!/usr/bin/php + -
+
+ + >" + >--> +
+ ';?> +
header">
+ + +
+ ';?> +
diff --git a/pages/helpers/body_close.php b/pages/helpers/body_close.php index d88d9ce..0f97e80 100755 --- a/pages/helpers/body_close.php +++ b/pages/helpers/body_close.php @@ -2,6 +2,5 @@ - diff --git a/pages/helpers/body_open.php b/pages/helpers/body_open.php index 68e3a98..d2a52cb 100755 --- a/pages/helpers/body_open.php +++ b/pages/helpers/body_open.php @@ -2,9 +2,7 @@ - - + diff --git a/pages/home.php b/pages/home.php index 66631fc..4d86cf8 100755 --- a/pages/home.php +++ b/pages/home.php @@ -4,19 +4,22 @@ --> -

Welcome!

+ - + <<home.jpg>>
+ ';?>
-
+

Thank you for visiting my site! My goal is to make the world a better place. Hopefully you find content here which helps empower @@ -24,9 +27,8 @@

- diff --git a/pages/media.php b/pages/media.php index 54e4338..1685700 100755 --- a/pages/media.php +++ b/pages/media.php @@ -8,15 +8,18 @@ } include "helpers/body_open.php"; ?> -

Media

+
-
+

My written works, social platforms, and photos can be found here.

@@ -32,11 +35,18 @@

I enjoy writing! Find my free eBooks below.

- +
    +
  • + 2025-09-28: Voluntary Sovereignty | + Existing in a statist society with the least amount of friction. +
  • +
  • +
  • + 2024-03-07: Hyperling's Health Protocol | + Health is a lifestyle, not a diet. Align yourself with Nature + to receive its blessings. +
  • +
@@ -107,7 +117,6 @@
- diff --git a/pages/photos.sh b/pages/photos.sh index 6e87a93..8cd0222 100755 --- a/pages/photos.sh +++ b/pages/photos.sh @@ -41,7 +41,7 @@ function start_main_page { echo -e "\t\t" >> $mainpage echo -e "\t\t
" >> $mainpage - echo -e "\t\t\t
" >> $mainpage + echo -e "\t\t\t
" >> $mainpage echo -en "\t\t\t\t

You may click on an album name to " >> $mainpage echo -en "view all of its files, or click on a specific image to bring up the " >> $mainpage echo -en "full resolution. On the album pages you may also click an image or " >> $mainpage diff --git a/pages/resources.php b/pages/resources.php index 832f821..a7b4a21 100755 --- a/pages/resources.php +++ b/pages/resources.php @@ -8,7 +8,6 @@ } include "helpers/body_open.php"; ?> -

Lists of Resources

@@ -68,7 +67,6 @@

- diff --git a/pages/resume.php b/pages/resume.php index b385119..4065887 100755 --- a/pages/resume.php +++ b/pages/resume.php @@ -8,12 +8,10 @@ } include "helpers/body_open.php"; ?> -

Resume

-
- -
+
+

Current Status : Traveling Full Time

@@ -21,25 +19,15 @@

Interested in hiring me? View my resume below!

- - +
- diff --git a/pages/subpages/home/announcements.php b/pages/subpages/home/announcements.php new file mode 100755 index 0000000..eef9ce4 --- /dev/null +++ b/pages/subpages/home/announcements.php @@ -0,0 +1,109 @@ +#!/usr/bin/php + +
+

Announcements

+
+ +
+
+ 2025-09-28 +

+ I wrote another short free eBook, "Voluntary Sovereignty", check it out + here! +

+ + It discusses how to live in order to create a truly free society, + as well as how to conduct oneself in today's authoritarian system. +

+

+ Learn what your rights are and how to avoid being harassed by + order followers while living how you were meant to be on the Earth. +

+ ";?> +

+ Watch the announcement here | (HyperVegan: "Announcements: Skipped Midfest, Voluntary Sovereignty eBook, CheapRVLiving Interview") +

+
+
+ +
+
+ 2025-03-27 +

+ My new Android app + "Expense Tracker" + has been completed! +

+ + It allows for tracking recurring expenses against income and static assets, + helping plan for financial planning and savings goals. +

+

+ This is my first app developed using the Flutter framework. +

+ ";?> +

+ Watch the announcement here | (HyperVegan: "Expense Tracker App") +

+
+ +
+ +
+
+ 2024-03-07 +

+ Find my free eBook, "Hyperling's Health Protocol", + here! +

+ + It contains a summary of my favorite and most useful lifestyle advice. +

+

+ These range across the basics of food / water / sleep / exercise + as well as less discussed topics of environment and positivity. +

+

+ Reverse chronic disease and live your life full of energy and abundance! +

+ ";?> +

+ Watch the announcement here | (HyperVegan: "My Health Protocol | eBook") +

+
+
+ +
+
+ 2024-03-31 +

+ There's a new app in town, + Tic-Tac-Toe! +

+ + This was written to learn Kotlin style Android programming. +

+

+ It allows playing against a range of automated opponents, + as well as a local human player! +

+ ";?> +

+ Watch the announcement here | (HyperVegan: "New Year, New App") +

+
+
diff --git a/pages/subpages/home/apps.php b/pages/subpages/home/apps.php deleted file mode 100755 index 4b5b0b1..0000000 --- a/pages/subpages/home/apps.php +++ /dev/null @@ -1,244 +0,0 @@ -#!/usr/bin/php -
-

My Profession

-
-
-
-

- I'm a professional software engineer who's been playing with - Linux system administration from a young age. Much of my career - has focused on back-end / database systems and optimizing - workflows. In my free time I enjoy learning new languages and - writing apps for Android. -

- -
-
- -
-

Public Programs

-
-
-
-

- Please feel welcome to use any of my free software below. -

-
-
- -
-

Android Apps

-
- -
- -
- -
- -
- Recurring Expense Tracker -
-
-
-

- Keep track of repeating expenses and - view projections of their effect on your finances. - First app written with Flutter. -

-

- - [Source Code] - [APKs / Obtainium URL] -

-
- -
- -
- -
- Tic-Tac-Toe -
-
-
-

- Play against a friend or a range of AIs. - Written to practice Kotlin/Compose. -

-

- - [Source Code] - [APKs / Obtainium URL] -

-
- -
- -
- -
- Carb Up! BETA -
-
-
-

- Calculate cost-effective foods on a High Carb Low Fat lifestyle. -

-

- - [Source Code] - [APKs / Obtainium URL] -

- -
- -
- -
- -
- Infinite Timer -
-
-
-

- Play a notification at your chosen interval. -

-

- - [Source Code] - [APKs / Obtainium URL] -

- -
- -
- -
- -
- 45 Minute Rule -
-
-
-

- Determine a good bedtime for waking during light sleep. -

-

- - [Source Code] - [APKs / Obtainium URL] -

- -
- -
- -
- -
- HyperGames -
-
-
-

- Started as a fun project for learning. - Playable but unfinished. -

-

- - [Source Code] - [APKs / Obtainium URL] -

- -
-
- -
-

Obtainium Configuration

-
- -
-
-

- In order to have the correct version numbers in Obtainium: -

- -

- Otherwise, "Take first link" works with pseudo versions. -

-
-
- -
-

Other Programs

-
-
-
-

- For a full list of software including my Ansible automation, - Docker setup, source code for this website, and other - fun/random toys, check out - My Projects. -

-
-
diff --git a/pages/subpages/support/donate.php b/pages/subpages/support/donate.php index 27cae62..38980b6 100755 --- a/pages/subpages/support/donate.php +++ b/pages/subpages/support/donate.php @@ -50,7 +50,7 @@ me@hyperling.com

- + <<zelle.png>>
diff --git a/pages/support.php b/pages/support.php index 42e3c42..2f367fa 100755 --- a/pages/support.php +++ b/pages/support.php @@ -8,19 +8,21 @@ } include "helpers/body_open.php"; ?> -

Support

+ - + <<support.jpg>>
-
+ ';?> +

Anything is very much appreciated!! Thank you for considering me!

- /dev/null + status=$? + if [[ $status != 0 ]]; then + log "Process '$$' not found, '$1' from '$DIR/$PROG' exiting." + exit 0 + fi +} + ## Parameters ## while getopts ':p:h' opt; do @@ -47,9 +69,6 @@ fi ## Build Environment ## -# Ensure we are executing from this file's directory. -cd $DIR - sudo="" if [[ -z $LOGNAME ]]; then LOGNAME="`whoami`" @@ -60,21 +79,29 @@ if [[ $LOGNAME != "root" ]]; then fi log "Check if any system dependencies need installed." +progs="" if [[ ! `which php` ]]; then echo "- Installing PHP" - $sudo apt-get install -y php-cli + progs="$progs php-cli" fi if [[ ! `which node` ]]; then echo "- Installing Node" - $sudo apt-get install -y nodejs + progs="$progs nodejs" fi if [[ ! `which npm` ]]; then echo "- Installing NPM" - $sudo apt-get install -y npm + progs="$progs npm" fi if [[ ! `which curl` ]]; then echo "- Installing Curl" - $sudo apt-get install -y curl + progs="$progs curl" +fi +if [[ ! `which ps` ]]; then + echo "- Installing PS" + progs="$progs procps" +fi +if [[ -n "$progs" ]]; then + $sudo apt-get install -y $progs fi # Directories and allowed page types are executable, others are not. @@ -95,6 +122,7 @@ npm install log "Removing old index files." find files/photos/ -name "*".html -print -delete { + check_main photos count=1 http_code=0 port="${ports%% *}" @@ -120,11 +148,21 @@ find files/photos/ -name "*".html -print -delete ## Main ## +log "Start local cronjob." +while true; do + check_main cronjob + $DIR/cronjob.sh + sleep 30 +done & + log "Start website API." node ./main.js $ports status=$? ## Finish ## +log "Kill spawned processes." +pkill -eP $$ + log "Exiting with status '$status'." exit $status