elonmusk 1.0.88 → 1.0.91
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README +2 -0
- data/README.md +59 -36
- data/VERSION_NUMBER +1 -1
- data/bin/ctit +44 -0
- data/documentation/ctit +7 -0
- data/documentation/page +8 -1
- data/gem_data/README +2 -0
- data/gem_data/VERSION_NUMBER +1 -1
- data/images/STORE.png +0 -0
- data/images/STORE2.png +0 -0
- data/index.html +103 -92
- data/non_compiled_programs/ctit +44 -0
- data/other/beautify_html_in_heredocs +8 -0
- data/{cleanup → other/cleanup} +1 -0
- data/other/communicate +88 -0
- data/other/experimental_code/ABOUT_S +1 -10
- data/other/experimental_code/a/six +0 -0
- data/other/experimental_code/odi +4 -10
- data/other/experimental_code/orig +11 -20
- data/other/experimental_code/pr.rb +1 -1
- metadata +13 -8
- data/other/experimental_code/a/a.out +0 -0
- data/other/experimental_code/a/hello_world +0 -0
- data/other/experimental_code/c_program_faster +0 -0
- /data/other/experimental_code/{Resume.pdf → description_of_what_ive_done_old.pdf} +0 -0
- /data/other/experimental_code/{merge → merge.rb} +0 -0
@@ -0,0 +1,44 @@
|
|
1
|
+
#!/usr/bin/ruby
|
2
|
+
# This is a work in progress.
|
3
|
+
|
4
|
+
ROMAN = /^([limcdvx]|[[:punct:]])+$/i
|
5
|
+
|
6
|
+
def capitalize(a)
|
7
|
+
a = a.gsub(/\s*(-|–|—|:)(-|–|—|:)*\s*/, "\\1 ")
|
8
|
+
w = a.split
|
9
|
+
not_major = /^(?:to|a|an|the|on|in|of|at|and|or|but|nor|for|yet|so)$/i
|
10
|
+
w = w.map do |i|
|
11
|
+
case i
|
12
|
+
when ROMAN
|
13
|
+
i.upcase
|
14
|
+
when /^(?:not|no|be|is|are|was|were|have|has|had|do|does|did|that|it|my|me|we|our|you|he|his|she|her|they|them|who)$/i
|
15
|
+
i.capitalize
|
16
|
+
when /(-|–|—|:)/
|
17
|
+
i.capitalize
|
18
|
+
when not_major
|
19
|
+
i.downcase
|
20
|
+
else
|
21
|
+
i.capitalize
|
22
|
+
end
|
23
|
+
end
|
24
|
+
w = w.to_a
|
25
|
+
if w.size == 0
|
26
|
+
w = [" "]
|
27
|
+
end
|
28
|
+
if w[0].match(ROMAN)
|
29
|
+
w[0] = w[0].upcase
|
30
|
+
else
|
31
|
+
w[0] = w[0].capitalize
|
32
|
+
end
|
33
|
+
if (w[-1].match(ROMAN))
|
34
|
+
w[-1] = w[-1].upcase
|
35
|
+
else
|
36
|
+
w[-1] = w[-1].capitalize
|
37
|
+
end
|
38
|
+
w = w.join(" ")
|
39
|
+
w = w.gsub "- ", "-"
|
40
|
+
w
|
41
|
+
end
|
42
|
+
|
43
|
+
|
44
|
+
print (capitalize ARGV.join(" "))
|
@@ -2,6 +2,14 @@
|
|
2
2
|
# frozen_string_literal: true
|
3
3
|
|
4
4
|
PROG1 = %w[htmlbeautifier clang-format][1]
|
5
|
+
puts PROG1
|
6
|
+
print "OK ? "
|
7
|
+
response = ""
|
8
|
+
response = STDIN.readline.strip while response.empty?
|
9
|
+
if response.match /[nN]/
|
10
|
+
abort
|
11
|
+
end
|
12
|
+
|
5
13
|
PROG2 = "rufo"
|
6
14
|
|
7
15
|
require "tempfile"
|
data/{cleanup → other/cleanup}
RENAMED
data/other/communicate
ADDED
@@ -0,0 +1,88 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
# frozen_string_literal: false
|
3
|
+
|
4
|
+
# BSD 2-Clause License
|
5
|
+
#
|
6
|
+
# Copyright (c) 2023, Gregory Cohen
|
7
|
+
# All rights reserved.
|
8
|
+
#
|
9
|
+
# Redistribution and use in source and binary forms, with or without
|
10
|
+
# modification, are permitted provided that the following conditions are met:
|
11
|
+
#
|
12
|
+
# 1. Redistributions of source code must retain the above copyright notice, this
|
13
|
+
# list of conditions and the following disclaimer.
|
14
|
+
#
|
15
|
+
# 2. Redistributions in binary form must reproduce the above copyright notice,
|
16
|
+
# this list of conditions and the following disclaimer in the documentation
|
17
|
+
# and/or other materials provided with the distribution.
|
18
|
+
#
|
19
|
+
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
20
|
+
# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
21
|
+
# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
22
|
+
# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
23
|
+
# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
24
|
+
# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
25
|
+
# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
26
|
+
# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
27
|
+
# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
28
|
+
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
29
|
+
require 'colored'
|
30
|
+
|
31
|
+
str = 'Enter '
|
32
|
+
|
33
|
+
$old_str = ''
|
34
|
+
def puts__(str, ack = false)
|
35
|
+
# def puts.old_str
|
36
|
+
return unless ENV['C_CODE'].nil?
|
37
|
+
# if ENV["C_CODE
|
38
|
+
# if
|
39
|
+
# requi
|
40
|
+
return if $old_str == str
|
41
|
+
|
42
|
+
str = str.to_s
|
43
|
+
def str.colorify
|
44
|
+
bold.send ''.colors.sample
|
45
|
+
end
|
46
|
+
|
47
|
+
def str.ack
|
48
|
+
['Thank you. '][0]
|
49
|
+
end
|
50
|
+
|
51
|
+
str.prepend str.ack if ack == true
|
52
|
+
print "#{str.colorify}\n"
|
53
|
+
|
54
|
+
system "echo '#{str}' | flite -voice slt "
|
55
|
+
end
|
56
|
+
|
57
|
+
alias :say puts__
|
58
|
+
|
59
|
+
count = 0
|
60
|
+
# speak str
|
61
|
+
|
62
|
+
def $stdin.readline
|
63
|
+
Dir.chdir Dir.home
|
64
|
+
Dir.chdir 'nerd-dictation'
|
65
|
+
res = ''
|
66
|
+
while res.strip == ''
|
67
|
+
res = %x(
|
68
|
+
./nerd-dictation begin --vosk-model-dir=`printf "%s\n" ./vosk-model-small-en-us* | head -n 1` --timeout 1.0 2>&1 --output STDOUT)
|
69
|
+
|
70
|
+
res = '' if res.downcase.include?('no text')
|
71
|
+
# STDOUT.print res
|
72
|
+
end
|
73
|
+
res
|
74
|
+
end
|
75
|
+
|
76
|
+
loop do
|
77
|
+
puts__ ARGV[0], ack = false
|
78
|
+
$text = $stdin.readline
|
79
|
+
|
80
|
+
class Object
|
81
|
+
def eval(*_args)
|
82
|
+
text = $text
|
83
|
+
Kernel.eval to_s
|
84
|
+
end
|
85
|
+
end
|
86
|
+
|
87
|
+
ARGV[1..-1].map(&:eval)
|
88
|
+
end
|
@@ -1,18 +1,9 @@
|
|
1
1
|
This is the entire stock history for the entire toronto stock exchange
|
2
2
|
|
3
|
-
|
4
|
-
|
5
3
|
This information is given out very publically from many different sources and websites.
|
6
4
|
|
7
|
-
|
8
|
-
|
9
5
|
Use this information for any purpose within reason.
|
10
6
|
|
11
|
-
|
12
|
-
|
13
7
|
I do not condone or support any illegal activity.
|
14
8
|
|
15
|
-
|
16
|
-
If I should or need to remove this from this repository, then please contact me and I can do so.
|
17
|
-
|
18
|
-
|
9
|
+
If I should or need to remove this from this repository, then please contact me and I can do so.
|
Binary file
|
data/other/experimental_code/odi
CHANGED
@@ -1,12 +1,6 @@
|
|
1
1
|
cd
|
2
2
|
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
3
|
+
for i in Desktop/*; do
|
4
|
+
gio set -t string "$i" metadata::caja-icon-position 00,00
|
5
|
+
caja -q &>/dev/null
|
6
|
+
done
|
@@ -1,14 +1,13 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
2
|
|
3
|
-
|
4
|
-
a
|
5
|
-
a += (
|
6
|
-
|
7
|
-
|
8
|
-
a.sample.to_s
|
3
|
+
a = ("a".."z").to_a
|
4
|
+
a += ("A".."Z").to_a
|
5
|
+
a += (0..9).to_a
|
6
|
+
foo = (((0..199).to_a.map do |i|
|
7
|
+
a.sample.to_s
|
9
8
|
end).join)
|
10
9
|
|
11
|
-
main_text =
|
10
|
+
main_text = <<EOF
|
12
11
|
From: <gregorycohenvideos@gmail.com>
|
13
12
|
To: gregorycohenvideos@gmail.com
|
14
13
|
MIME-Version: 1.0
|
@@ -19,15 +18,11 @@ Content-Type: text/plain; charset=utf-8
|
|
19
18
|
Content-Transfer-Encoding: 7bit\n\nMessage\n
|
20
19
|
EOF
|
21
20
|
|
22
|
-
|
23
21
|
for arg in ARGV; file_text = File.read arg
|
24
|
-
|
25
|
-
|
22
|
+
if file_text == foo
|
23
|
+
raise
|
26
24
|
end
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
main_text += <<EOF
|
25
|
+
main_text += <<EOF
|
31
26
|
|
32
27
|
--#{foo}
|
33
28
|
Content-Disposition: attachment; filename="#{arg}"
|
@@ -35,15 +30,11 @@ Content-Type: text/plain
|
|
35
30
|
|
36
31
|
#{file_text}
|
37
32
|
|
38
|
-
EOF
|
39
|
-
|
40
|
-
|
41
|
-
end
|
33
|
+
EOF end
|
42
34
|
|
43
35
|
main_text += "--#{foo}--"
|
44
36
|
puts main_text
|
45
37
|
|
46
38
|
IO.popen("himalaya send", "w") do |f|
|
47
|
-
|
39
|
+
f.print main_text.gsub("\n", "\r\n")
|
48
40
|
end
|
49
|
-
|
metadata
CHANGED
@@ -1,18 +1,20 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: elonmusk
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.91
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gregory Cohen
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-06-
|
11
|
+
date: 2023-06-18 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: |+
|
14
14
|
Trying to help with democracy. (No affiliation with elonmusk.)
|
15
15
|
|
16
|
+
https://snapcraft.io/democracy
|
17
|
+
|
16
18
|
This is a collection of software that could truly change the world.
|
17
19
|
|
18
20
|
All of these programs are mostly self-contained. This is a really good thing.
|
@@ -69,6 +71,7 @@ files:
|
|
69
71
|
- "./bin/clock"
|
70
72
|
- "./bin/close"
|
71
73
|
- "./bin/copy"
|
74
|
+
- "./bin/ctit"
|
72
75
|
- "./bin/cyan"
|
73
76
|
- "./bin/cyan_bold"
|
74
77
|
- "./bin/cyan_bold_underline"
|
@@ -132,7 +135,6 @@ files:
|
|
132
135
|
- "./bin/yellow_bold"
|
133
136
|
- "./bin/yellow_bold_underline"
|
134
137
|
- "./bin/yellow_underline"
|
135
|
-
- "./cleanup"
|
136
138
|
- "./democracy.gemspec"
|
137
139
|
- "./discourse generator 1/PROGRAM.rb"
|
138
140
|
- "./discourse generator 1/RANDOM_INPUT_TEST_OUT"
|
@@ -177,6 +179,7 @@ files:
|
|
177
179
|
- "./documentation/clock"
|
178
180
|
- "./documentation/close"
|
179
181
|
- "./documentation/copy"
|
182
|
+
- "./documentation/ctit"
|
180
183
|
- "./documentation/cyan"
|
181
184
|
- "./documentation/cyan_bold"
|
182
185
|
- "./documentation/cyan_bold_underline"
|
@@ -23266,12 +23269,15 @@ files:
|
|
23266
23269
|
- "./images/7.png"
|
23267
23270
|
- "./images/8.png"
|
23268
23271
|
- "./images/9.png"
|
23272
|
+
- "./images/STORE.png"
|
23273
|
+
- "./images/STORE2.png"
|
23269
23274
|
- "./index.html"
|
23270
23275
|
- "./install.sh"
|
23271
23276
|
- "./non_compiled_programs/big_num"
|
23272
23277
|
- "./non_compiled_programs/chat_rb"
|
23273
23278
|
- "./non_compiled_programs/close"
|
23274
23279
|
- "./non_compiled_programs/copy"
|
23280
|
+
- "./non_compiled_programs/ctit"
|
23275
23281
|
- "./non_compiled_programs/dictate"
|
23276
23282
|
- "./non_compiled_programs/email"
|
23277
23283
|
- "./non_compiled_programs/emoji"
|
@@ -23291,6 +23297,8 @@ files:
|
|
23291
23297
|
- "./other/best_programming_language/emeraldc.cr"
|
23292
23298
|
- "./other/best_programming_language/example.c"
|
23293
23299
|
- "./other/best_programming_language/out_0.c"
|
23300
|
+
- "./other/cleanup"
|
23301
|
+
- "./other/communicate"
|
23294
23302
|
- "./other/democracy.gemspec"
|
23295
23303
|
- "./other/discourse_generator_desktop_widget/.qmake.stash"
|
23296
23304
|
- "./other/discourse_generator_desktop_widget/a.cpp"
|
@@ -23310,10 +23318,7 @@ files:
|
|
23310
23318
|
- "./other/emerald-browser/src/ss.h"
|
23311
23319
|
- "./other/emerald-browser/test/a.cpp"
|
23312
23320
|
- "./other/experimental_code/ABOUT_S"
|
23313
|
-
- "./other/experimental_code/Resume.pdf"
|
23314
23321
|
- "./other/experimental_code/a/a (1).tar.gz"
|
23315
|
-
- "./other/experimental_code/a/a.out"
|
23316
|
-
- "./other/experimental_code/a/hello_world"
|
23317
23322
|
- "./other/experimental_code/a/help"
|
23318
23323
|
- "./other/experimental_code/a/main_v1.cpp"
|
23319
23324
|
- "./other/experimental_code/a/my_libs_gregory/.libs/mod_my_libs_gregory.lai"
|
@@ -23325,8 +23330,8 @@ files:
|
|
23325
23330
|
- "./other/experimental_code/a/nginx.conf"
|
23326
23331
|
- "./other/experimental_code/a/six"
|
23327
23332
|
- "./other/experimental_code/c_prog"
|
23328
|
-
- "./other/experimental_code/c_program_faster"
|
23329
23333
|
- "./other/experimental_code/crypto"
|
23334
|
+
- "./other/experimental_code/description_of_what_ive_done_old.pdf"
|
23330
23335
|
- "./other/experimental_code/find_abs_best"
|
23331
23336
|
- "./other/experimental_code/get_data"
|
23332
23337
|
- "./other/experimental_code/github"
|
@@ -23335,7 +23340,7 @@ files:
|
|
23335
23340
|
- "./other/experimental_code/loop.js"
|
23336
23341
|
- "./other/experimental_code/m.c"
|
23337
23342
|
- "./other/experimental_code/man/foo.rb"
|
23338
|
-
- "./other/experimental_code/merge"
|
23343
|
+
- "./other/experimental_code/merge.rb"
|
23339
23344
|
- "./other/experimental_code/odi"
|
23340
23345
|
- "./other/experimental_code/orig"
|
23341
23346
|
- "./other/experimental_code/pr.rb"
|
Binary file
|
Binary file
|
Binary file
|
File without changes
|
File without changes
|