chid 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/CHANGELOG.md +11 -0
- data/Gemfile +4 -0
- data/Gemfile.lock +67 -0
- data/README.md +221 -0
- data/Rakefile +17 -0
- data/chid.gemspec +32 -0
- data/etc/img/stack.png +0 -0
- data/lib/chid.rb +100 -0
- data/lib/chid/chid_config.rb +127 -0
- data/lib/chid/currency_api.rb +69 -0
- data/lib/chid/github_api.rb +41 -0
- data/lib/chid/main.rb +112 -0
- data/lib/chid/news_api.rb +60 -0
- data/lib/chid/paginator.rb +57 -0
- data/lib/chid/stack_overflow_api.rb +35 -0
- data/lib/chid/version.rb +3 -0
- data/lib/chid/yandex_translate_api.rb +39 -0
- data/tasks/chid/config.rake +5 -0
- data/tasks/chid/init.rake +19 -0
- data/tasks/chid/start.rake +26 -0
- data/tasks/chid/update.rake +14 -0
- data/tasks/currency/convert.rake +9 -0
- data/tasks/currency/current.rake +11 -0
- data/tasks/currency/list.rake +10 -0
- data/tasks/github.rake +12 -0
- data/tasks/help.rake +8 -0
- data/tasks/install/node.rake +18 -0
- data/tasks/install/postgres.rake +18 -0
- data/tasks/install/rvm.rake +21 -0
- data/tasks/install/yadr_dotfiles.rake +26 -0
- data/tasks/news.rake +11 -0
- data/tasks/run/postgres.rake +12 -0
- data/tasks/stack_overflow.rake +20 -0
- data/tasks/tmux/config_windows.rake +21 -0
- data/tasks/tmux/new_session.rake +10 -0
- data/tasks/translate/yandex_list.rake +7 -0
- data/tasks/translate/yandex_translate.rake +8 -0
- data/tasks/update/os.rake +14 -0
- data/tasks/workstation/create.rake +23 -0
- data/tasks/workstation/destroy.rake +14 -0
- data/tasks/workstation/list.rake +10 -0
- data/tasks/workstation/open.rake +29 -0
- metadata +158 -0
@@ -0,0 +1,29 @@
|
|
1
|
+
namespace :workstation do
|
2
|
+
|
3
|
+
desc 'Open a specific workstation'
|
4
|
+
task :open, [:workstation] do |t, args|
|
5
|
+
workstations = @chid_config.all_workstations
|
6
|
+
|
7
|
+
workstation_name = args[:workstation]
|
8
|
+
apps = workstations[workstation_name.to_sym] unless workstation_name.nil?
|
9
|
+
|
10
|
+
if apps.nil?
|
11
|
+
prompt = TTY::Prompt.new
|
12
|
+
choices = workstations.keys
|
13
|
+
result = prompt.select('Choose a workstation to open', choices)
|
14
|
+
apps = workstations[result.to_sym]
|
15
|
+
end
|
16
|
+
|
17
|
+
puts "\nOpening all Apps"
|
18
|
+
apps.each do |app_name|
|
19
|
+
@chid_config.on_osx do
|
20
|
+
system("open -a #{app_name}")
|
21
|
+
end
|
22
|
+
|
23
|
+
@chid_config.on_linux do
|
24
|
+
system("#{app_name} >/dev/null 2>&1 &")
|
25
|
+
end
|
26
|
+
end
|
27
|
+
end
|
28
|
+
|
29
|
+
end
|
metadata
ADDED
@@ -0,0 +1,158 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: chid
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.2
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Rachid Calazans
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2017-07-11 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: pry
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '0'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ">="
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '0'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: rake
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ">="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0'
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ">="
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: http
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - ">="
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '0'
|
48
|
+
type: :runtime
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - ">="
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: tty-prompt
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ">="
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
type: :runtime
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: easy_translate
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0'
|
76
|
+
type: :runtime
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ">="
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '0'
|
83
|
+
description: Chid is an assistant to help your day-to-day life. It can be used in
|
84
|
+
some installations, news, configurations, workstations and more.
|
85
|
+
email:
|
86
|
+
- rachidcalazans@gmail.com
|
87
|
+
executables: []
|
88
|
+
extensions: []
|
89
|
+
extra_rdoc_files: []
|
90
|
+
files:
|
91
|
+
- CHANGELOG.md
|
92
|
+
- Gemfile
|
93
|
+
- Gemfile.lock
|
94
|
+
- README.md
|
95
|
+
- Rakefile
|
96
|
+
- chid.gemspec
|
97
|
+
- etc/img/stack.png
|
98
|
+
- lib/chid.rb
|
99
|
+
- lib/chid/chid_config.rb
|
100
|
+
- lib/chid/currency_api.rb
|
101
|
+
- lib/chid/github_api.rb
|
102
|
+
- lib/chid/main.rb
|
103
|
+
- lib/chid/news_api.rb
|
104
|
+
- lib/chid/paginator.rb
|
105
|
+
- lib/chid/stack_overflow_api.rb
|
106
|
+
- lib/chid/version.rb
|
107
|
+
- lib/chid/yandex_translate_api.rb
|
108
|
+
- tasks/chid/config.rake
|
109
|
+
- tasks/chid/init.rake
|
110
|
+
- tasks/chid/start.rake
|
111
|
+
- tasks/chid/update.rake
|
112
|
+
- tasks/currency/convert.rake
|
113
|
+
- tasks/currency/current.rake
|
114
|
+
- tasks/currency/list.rake
|
115
|
+
- tasks/github.rake
|
116
|
+
- tasks/help.rake
|
117
|
+
- tasks/install/node.rake
|
118
|
+
- tasks/install/postgres.rake
|
119
|
+
- tasks/install/rvm.rake
|
120
|
+
- tasks/install/yadr_dotfiles.rake
|
121
|
+
- tasks/news.rake
|
122
|
+
- tasks/run/postgres.rake
|
123
|
+
- tasks/stack_overflow.rake
|
124
|
+
- tasks/tmux/config_windows.rake
|
125
|
+
- tasks/tmux/new_session.rake
|
126
|
+
- tasks/translate/yandex_list.rake
|
127
|
+
- tasks/translate/yandex_translate.rake
|
128
|
+
- tasks/update/os.rake
|
129
|
+
- tasks/workstation/create.rake
|
130
|
+
- tasks/workstation/destroy.rake
|
131
|
+
- tasks/workstation/list.rake
|
132
|
+
- tasks/workstation/open.rake
|
133
|
+
homepage: https://github.com/rachidcalazans/chid
|
134
|
+
licenses:
|
135
|
+
- MIT
|
136
|
+
metadata: {}
|
137
|
+
post_install_message:
|
138
|
+
rdoc_options: []
|
139
|
+
require_paths:
|
140
|
+
- lib
|
141
|
+
- tasks
|
142
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
143
|
+
requirements:
|
144
|
+
- - ">="
|
145
|
+
- !ruby/object:Gem::Version
|
146
|
+
version: '0'
|
147
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
148
|
+
requirements:
|
149
|
+
- - ">="
|
150
|
+
- !ruby/object:Gem::Version
|
151
|
+
version: '0'
|
152
|
+
requirements: []
|
153
|
+
rubyforge_project:
|
154
|
+
rubygems_version: 2.6.6
|
155
|
+
signing_key:
|
156
|
+
specification_version: 4
|
157
|
+
summary: Simple assistant for day-to-day life. Developers and common users
|
158
|
+
test_files: []
|