From 7c6828abddf5bdf994942f00781d49db96457e19 Mon Sep 17 00:00:00 2001 From: Erovia Date: Thu, 27 May 2021 22:02:26 +0100 Subject: [PATCH 1/4] World domination --- lib/python/qmk/cli/__init__.py | 1 + lib/python/qmk/cli/bux.py | 47 ++++++++++++++++++++++++++++++++++ 2 files changed, 48 insertions(+) create mode 100755 lib/python/qmk/cli/bux.py diff --git a/lib/python/qmk/cli/__init__.py b/lib/python/qmk/cli/__init__.py index be5ba90ad74a..d07790d1182a 100644 --- a/lib/python/qmk/cli/__init__.py +++ b/lib/python/qmk/cli/__init__.py @@ -135,6 +135,7 @@ def _broken_module_imports(requirements): exit(1) # Import our subcommands +from . import bux # noqa from . import c2json # noqa from . import cformat # noqa from . import chibios # noqa diff --git a/lib/python/qmk/cli/bux.py b/lib/python/qmk/cli/bux.py new file mode 100755 index 000000000000..fc2f3f03cd8f --- /dev/null +++ b/lib/python/qmk/cli/bux.py @@ -0,0 +1,47 @@ +"""QMK Bux + +World domination secret weapon. +""" +from milc import cli +from milc.subcommand import config + + +@cli.subcommand('QMK Hello World.', hidden=True) +def bux(cli): + """QMK bux + """ + if not cli.config.user.bux: + bux = 0 + else: + bux = cli.config.user.bux + + cli.args.read_only = False + config.set_config('user', 'bux', bux + 1) + cli.save_config() + + buck = """ +@@BBBBBBBBBBBBBBBBBBBBK `vP8#####BE2~ x###g_ `S###q n##} -j#Bl. vBBBBBBBBBBBBBBBBBBBB@@ +@B `:!: ^#@#]- `!t@@&. 7@@B@#^ _Q@Q@@R y@@l:P@#1' `!!_ B@ +@B r@@@B g@@| ` N@@u 7@@iv@@u *#@z"@@R y@@&@@Q- l@@@D B@ +@B !#@B ^#@#x- I@B@@&' 7@@i "B@Q@@r _@@R y@@l.k#@W: `:@@D B@ +@B B@B `v3g#####B0N#d. v##x 'ckk: -##A u##i `lB#I_ @@D B@ +@B B@B @@D B@ +@B B@B `._":!!!=~^*|)r^~:' @@D B@ +@B ~*~ `,=)]}y2tjIIfKfKfaPsffsWsUyx~. **! B@ +@B .*r***r= _*]yzKsqKUfz22IAA3HzzUjtktzHWsHsIz]. B@ +@B )v` , !1- -rysHHUzUzo2jzoI22ztzkyykt2zjzUzIa3qPsl' !r*****` B@ +@B :} @` .j `xzqdAfzKWsj2kkcycczqAsk2zHbg&ER5q55SNN5U~ !RBB#d`c#1 f#\BQ&v B@ +@B _y ]# ,c vUWNWWPsfsssN9WyccnckAfUfWb0DR0&R5RRRddq2_ `@D`jr@2U@#c3@1@Qc- B@ +@B !7! .r]` }AE0RdRqNd9dNR9fUIzzosPqqAddNNdER9EE9dPy! BQ!zy@iU@.Q@@y@8x- B@ +@B :****>. '7adddDdR&gRNdRbd&dNNbbRdNdd5NdRRD0RSf}- .k0&EW`xR .8Q=NRRx B@ +@B =**-rx*r}r~}" ;n2jkzsf3N3zsKsP5dddRddddRddNNqPzy\" '~****" B@ +@B :!!~!;=~r>:*_ `:^vxikylulKfHkyjzzozoIoklix|^!-` B@ +@B ```'-_""::::!:_-.`` B@ +@B `- .` B@ +@B -g@= `}&###E7 W#g. :#Q n####~ R###8k ;#& `##.7#8-`R#z t@H B@ +@B r@= 8@R=-=R@g R@@#:!@@ 2@&!:` 8@1=@@!*@B `@@- v@#8@y @H B@ +@B r@= :@@- _@@_R@fB#}@@ 2@@@# 8@@#@Q.*@B `@@- y@@N @H B@ +@B `. g@9=_~D@g R@}`&@@@ 2@&__` 8@u_Q@2!@@^-x@@` Y@QD@z .` B@ +@@BBBBBBBBBBBBBBBBBBB_ `c8@@@81` S#] `N#B l####v D###BA. vg@@#0~ i#&' 5#K RBBBBBBBBBBBBBBBBBB@@ +""" # noqa: Do not care about the ASCII art + print(f"{buck}\nYou've been blessed with by the QMK gods!\nYou {cli.config.user.bux} QMK bux.") From 36cc9c9bfeff3f83fbf8c9fc01fc2132ec1fcdc1 Mon Sep 17 00:00:00 2001 From: Erovia Date: Fri, 28 May 2021 17:03:31 +0100 Subject: [PATCH 2/4] Fix typo Co-authored-by: Nick Brassel --- lib/python/qmk/cli/bux.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/python/qmk/cli/bux.py b/lib/python/qmk/cli/bux.py index fc2f3f03cd8f..4059afa9e27a 100755 --- a/lib/python/qmk/cli/bux.py +++ b/lib/python/qmk/cli/bux.py @@ -44,4 +44,4 @@ def bux(cli): @B `. g@9=_~D@g R@}`&@@@ 2@&__` 8@u_Q@2!@@^-x@@` Y@QD@z .` B@ @@BBBBBBBBBBBBBBBBBBB_ `c8@@@81` S#] `N#B l####v D###BA. vg@@#0~ i#&' 5#K RBBBBBBBBBBBBBBBBBB@@ """ # noqa: Do not care about the ASCII art - print(f"{buck}\nYou've been blessed with by the QMK gods!\nYou {cli.config.user.bux} QMK bux.") + print(f"{buck}\nYou've been blessed with by the QMK gods!\nYou have {cli.config.user.bux} QMK bux.") From 35b83eee1c39b0be944e6e7faa72dbe91948be74 Mon Sep 17 00:00:00 2001 From: Erovia Date: Fri, 28 May 2021 17:08:08 +0100 Subject: [PATCH 3/4] Add motto, fix typo --- lib/python/qmk/cli/bux.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/python/qmk/cli/bux.py b/lib/python/qmk/cli/bux.py index 4059afa9e27a..fbe58adf272d 100755 --- a/lib/python/qmk/cli/bux.py +++ b/lib/python/qmk/cli/bux.py @@ -38,10 +38,12 @@ def bux(cli): @B :!!~!;=~r>:*_ `:^vxikylulKfHkyjzzozoIoklix|^!-` B@ @B ```'-_""::::!:_-.`` B@ @B `- .` B@ +@B r@= In source we trust @H B@ +@B r@= @H B@ @B -g@= `}&###E7 W#g. :#Q n####~ R###8k ;#& `##.7#8-`R#z t@H B@ @B r@= 8@R=-=R@g R@@#:!@@ 2@&!:` 8@1=@@!*@B `@@- v@#8@y @H B@ @B r@= :@@- _@@_R@fB#}@@ 2@@@# 8@@#@Q.*@B `@@- y@@N @H B@ @B `. g@9=_~D@g R@}`&@@@ 2@&__` 8@u_Q@2!@@^-x@@` Y@QD@z .` B@ @@BBBBBBBBBBBBBBBBBBB_ `c8@@@81` S#] `N#B l####v D###BA. vg@@#0~ i#&' 5#K RBBBBBBBBBBBBBBBBBB@@ """ # noqa: Do not care about the ASCII art - print(f"{buck}\nYou've been blessed with by the QMK gods!\nYou have {cli.config.user.bux} QMK bux.") + print(f"{buck}\nYou've been blessed by the QMK gods!\nYou have {cli.config.user.bux} QMK bux.") From 6e874a2bad5a7957165b83fb83b7e4c4c596fb02 Mon Sep 17 00:00:00 2001 From: Erovia Date: Fri, 28 May 2021 17:14:20 +0100 Subject: [PATCH 4/4] Stating the facts Co-authored-by: Ryan --- lib/python/qmk/cli/bux.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/python/qmk/cli/bux.py b/lib/python/qmk/cli/bux.py index fbe58adf272d..504ee35d6e2d 100755 --- a/lib/python/qmk/cli/bux.py +++ b/lib/python/qmk/cli/bux.py @@ -6,7 +6,7 @@ from milc.subcommand import config -@cli.subcommand('QMK Hello World.', hidden=True) +@cli.subcommand('QMK Bux miner.', hidden=True) def bux(cli): """QMK bux """