diff options
| author | Paul Buetow <paul@buetow.org> | 2023-07-27 23:30:19 +0300 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2023-07-27 23:30:19 +0300 |
| commit | 52a20b00f26c1f8d3e695b3af6ccf47a3198d7d8 (patch) | |
| tree | 1474b06f797a05e9aa72d0cd9a8722e5a2486563 | |
| parent | 7d053aa8e0ea92fdbdbded609b39f42abea37b08 (diff) | |
remove habit
| -rw-r--r-- | frontends/Rexfile | 18 | ||||
| -rw-r--r-- | frontends/etc/inetd.conf | 2 | ||||
| -rw-r--r-- | frontends/scripts/habit.pl | 57 |
3 files changed, 1 insertions, 76 deletions
diff --git a/frontends/Rexfile b/frontends/Rexfile index c9740af..96b3035 100644 --- a/frontends/Rexfile +++ b/frontends/Rexfile @@ -8,7 +8,7 @@ # Rex is programmed in Perl and there is already Perl in the base system of OpenBSD. # Also, I find Perl > Python (my personal opinion). -use Rex -feature => ['1.14']; +use Rex -feature => ['1.14', 'exec_autodie']; use Rex::Logger; use File::Slurp; @@ -251,21 +251,6 @@ task 'inetd', group => 'frontends', service 'inetd', ensure => 'started'; }; -desc 'Setup habit'; -task 'habit', group => 'frontends', - sub { - pkg 'cowsay', ensure => present; - run 'adduser -class inetd -group _habit -batch _habit', unless => 'id _habit'; - - file '/usr/local/bin/habit.pl', - source => './scripts/habit.pl', - owner => 'root', - group => 'wheel', - mode => '755'; - - append_if_no_such_line '/etc/daily.local', 'perl -T /usr/local/bin/habit.pl'; - }; - desc 'Setup relayd'; task 'relayd', group => 'frontends', sub { @@ -537,7 +522,6 @@ task 'commons', group => 'frontends', acme(); acme_invoke(); inetd(); - habit(); relayd(); smtpd(); rsync(); diff --git a/frontends/etc/inetd.conf b/frontends/etc/inetd.conf index 22eae50..1316387 100644 --- a/frontends/etc/inetd.conf +++ b/frontends/etc/inetd.conf @@ -1,4 +1,2 @@ 127.0.0.1:11965 stream tcp nowait www /usr/local/bin/vger vger -v rsync stream tcp nowait root /usr/local/bin/rsync rsyncd --daemon -*:1234 stream tcp nowait _habit /usr/bin/perl perl -T /usr/local/bin/habit.pl -# *:4242 stream tcp nowait _failunderd /bin/cat cat /var/run/failunderd/status.json diff --git a/frontends/scripts/habit.pl b/frontends/scripts/habit.pl deleted file mode 100644 index c8ca2e8..0000000 --- a/frontends/scripts/habit.pl +++ /dev/null @@ -1,57 +0,0 @@ -#!/usr/bin/perl -T - -use v5.36; -use strict; -use warnings; - -use Acme::Cow; - -our @habits = ( - '1h+ deep work', - 'Breathing exercise', - 'Do nothing', - 'Do pistol squads', - 'Do Push-ups', - 'Do Shoulder stand', - 'Do single-arm push-ups', - 'Do Yoga Bridge', - 'Do Yoga Cro', - 'Do Yoga Downward Facing Dog', - 'Do Yoga Half Moon', - 'Do Yoga Warrior 3', - 'Do Yoga Wheel', - 'Drink tea (or an infusion)', - 'Drink water', - 'Eat 99% dark chocolate', - 'Enjoy my current task', - 'Focus on things I have under control', - 'Got enough vitamins?', - 'Have a positive attitute - Be solution oriented', - 'Watch bulgarian TV or YouTube', - 'Have a walk without headphones plugged in', - 'Help someone', - 'It\'s family time', - 'Learn/try out a new Linux/Unix command', - 'Learn vocs with Anki', - 'Limit the use of social media', - 'Listen to a random 101 chapter today', - 'Listen to music', - 'Meditate', - 'Only use my phone and computers intentionally', - 'Play with the cat', - 'Process my last (book) notes', - 'Read my Gemini subscriptions', - "Read today's chapter of the daily stoic", - 'Revisit my core values', - 'Take it easy - nobody is dying!', - 'Think about the purpose of what I am doing', - 'Tonight, disconnect from work completely', - 'Write down 10 ideas (weird and non-weird)', - 'Write down 3 things I am grateful for', -); - -my $habit = $habits[rand @habits]; -my $cow = Acme::Cow->new; -$cow->text($habit); -int(rand 2) ? $cow->say : $cow->think; -$cow->print; |
