From 5a362e310d555c8d72359ca54474484674ff5b8e Mon Sep 17 00:00:00 2001 From: Lynnesbian Date: Sun, 5 Apr 2020 02:44:35 +1000 Subject: [PATCH] added a way past cool CLI thingy --- _plugins/extensions.rb | 38 ++++++++++++++++++++++++++++++++++++++ cli.txt | 25 +++++++++++++++++++++++++ retro.html | 2 +- 3 files changed, 64 insertions(+), 1 deletion(-) create mode 100644 _plugins/extensions.rb create mode 100644 cli.txt diff --git a/_plugins/extensions.rb b/_plugins/extensions.rb new file mode 100644 index 0000000..f7272da --- /dev/null +++ b/_plugins/extensions.rb @@ -0,0 +1,38 @@ +require "liquid" +require "jekyll" + +module Jekyll + module LynnesbianDotSpaceFilters + def ansi_colour(code) + "\u001b[38;5;#{code}m" + end + + def ansi_bg(code) + "\u001b[48;5;#{code}m" + end + end + + class AnsiResetTag < Liquid::Tag + def render(context) + "\u001b[0m" + end + end + + class AnsiBoldTag < Liquid::Tag + def render(context) + "\u001b[1m" + end + end + + class AnsiUnderlineTag < Liquid::Tag + def render(context) + "\u001b[4m" + end + end +end + + +Liquid::Template.register_filter(Jekyll::LynnesbianDotSpaceFilters) +Liquid::Template.register_tag('ansi_reset', Jekyll::AnsiResetTag) +Liquid::Template.register_tag('ansi_bold', Jekyll::AnsiBoldTag) +Liquid::Template.register_tag('ansi_underline', Jekyll::AnsiUnderlineTag) \ No newline at end of file diff --git a/cli.txt b/cli.txt new file mode 100644 index 0000000..f8e216c --- /dev/null +++ b/cli.txt @@ -0,0 +1,25 @@ +--- +--- +{%- assign cyan = 87 | ansi_colour -%} +{%- assign purple = 99 | ansi_colour -%} +{{ purple }}{{ 231 | ansi_bg }}{% ansi_bold %}▞▚▞▚▞▚▖ ▂▃▄▅▆▇█{{99 | ansi_bg }}{{ 231 | ansi_colour }} lynnesbian dot space {{ purple }}{{ 231 | ansi_bg }}█▇▆▅▄▃▂ ▗▞▚▞▚▞▚{% ansi_reset %} + {{ purple }} {% ansi_underline %} {{ cyan }} {% ansi_reset %} + {{ purple }} ╱ ╱ {{ cyan }} ╱{% ansi_reset %} + {{ purple }} ╱ ╱ {{ cyan }} ╱{% ansi_reset %} + {{ cyan }} ╱ ╱ ╱{% ansi_reset %} + {{ cyan }} ╱ {% ansi_underline %}╱ {% ansi_reset %}{{ cyan }}╱{% ansi_reset %} + {{ cyan }} {% ansi_underline %}╱ {% ansi_reset %}{{ cyan }}╱{% ansi_reset %} +{{ 81 | ansi_bg }} {{ 213 | ansi_bg }} {{ 231 | ansi_bg }} {{ 213 | ansi_bg }} {{ 81 | ansi_bg }} {% ansi_reset %} +╭──────────────────────────────────────┬───────────────────────────────────────╮ +│ Name │ Lynne, aka Lynnesbian │ +│ Born │ 1998-04-02 (April 2nd, 1998) │ +│ Timezone │ Australia/Brisbane - AEST - UTC+1000 │ +│ What I do │ Free and open source software │ +│ Fediverse account │ @lynnesbian@fedi.lynnesbian.space │ +│ Email │ @lynne@bune.city │ +│ Blog │ https://bune.city │ +│ Be gay │ Do crimes │ +╰──────────────────────────────────────┴───────────────────────────────────────╯ +{{ 81 | ansi_bg }} {{ 213 | ansi_bg }} {{ 231 | ansi_bg }} {{ 213 | ansi_bg }} {{ 81 | ansi_bg }} {% ansi_reset %} + +{{ purple }}{{ 231 | ansi_bg }}{% ansi_bold %}░▒▓▒░▒▓▒░▒▓▒░▒▓▒░ Source code: https://l.bune.city/clisrc ░▒▓▒░▒▓▒░▒▓▒░▒▓▒░▓▒░{% ansi_reset %} diff --git a/retro.html b/retro.html index e7d570b..5455e28 100644 --- a/retro.html +++ b/retro.html @@ -51,7 +51,7 @@ less_important: true

Who?

- My name is Lynne, a twenty-one year old woman living in Australia (the land down under!) + My name is Lynne, a twenty-two year old woman living in Australia (the land down under!)