gistim 0.2.1 → 0.2.2
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/+x +0 -0
- data/Gemfile.lock +2 -2
- data/bin/gistimnow +25 -0
- data/exe/gistim +10 -1
- data/gistim.gemspec +1 -1
- data/lib/gistim/version.rb +1 -1
- metadata +5 -4
- data/.gistim.tmp +0 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 03d622ef69c9d08fe19c0821b882f7fd7068e0c9185a2388b4fde375890f3ba4
|
|
4
|
+
data.tar.gz: 16dfc4681a429cc0b9b076079c24fd807cc98fc5214ff6363cb0dfa810fc8c51
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 3f7b3089357162ccdb2892828f4328131d5d32bdb9e3d5cf498dbd0a25e5a51f6c8327e3efdfdc89abf36ba98ab2ce188c32fab41fb4c6914155b76ca0c7a968
|
|
7
|
+
data.tar.gz: 18f689fb1200170b1f58f5c610253f467831179a710439af283c31b90d2d53e377c5ccd17b491b87f0e0bd4dbe893e8bb9b5fef0ab22568d21683432280739c9
|
data/+x
ADDED
|
File without changes
|
data/Gemfile.lock
CHANGED
data/bin/gistimnow
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
#!/bin/bash -eu
|
|
2
|
+
|
|
3
|
+
readonly gistim_home=${GISTIM_HOME:-$HOME/gistim}
|
|
4
|
+
|
|
5
|
+
mkdir -p "$gistim_home"
|
|
6
|
+
|
|
7
|
+
for arg in "$@"; do
|
|
8
|
+
[ "$arg" = '--list' ] && find "$gistim_home" -type d -maxdepth 1 && exit
|
|
9
|
+
[ "$arg" = '--path' ] && echo "$gistim_home" && exit
|
|
10
|
+
[ "$arg" = '--version' ] && gistim --version && exit
|
|
11
|
+
done
|
|
12
|
+
|
|
13
|
+
pushd "$gistim_home"
|
|
14
|
+
|
|
15
|
+
permitted_options=''
|
|
16
|
+
for arg in "$@"; do
|
|
17
|
+
[[ "$arg" =~ ^[^-].+$ ]] && $permitted_options="$permitted_options $arg"
|
|
18
|
+
done
|
|
19
|
+
|
|
20
|
+
gistim create $permitted_options
|
|
21
|
+
|
|
22
|
+
return_to_current_directory=true
|
|
23
|
+
|
|
24
|
+
[ "$return_to_current_directory" ] && pushd
|
|
25
|
+
|
data/exe/gistim
CHANGED
|
@@ -4,6 +4,13 @@ require 'pry'
|
|
|
4
4
|
require 'gistim'
|
|
5
5
|
subcommand = ARGV[0]
|
|
6
6
|
|
|
7
|
+
# TODO: Use Ruby OptionParser
|
|
8
|
+
|
|
9
|
+
if ARGV.include? '--version'
|
|
10
|
+
puts Gistim::VERSION
|
|
11
|
+
exit
|
|
12
|
+
end
|
|
13
|
+
|
|
7
14
|
if subcommand == 'help'
|
|
8
15
|
puts <<~HELP
|
|
9
16
|
$ gistim create some_word
|
|
@@ -12,9 +19,11 @@ if subcommand == 'help'
|
|
|
12
19
|
HELP
|
|
13
20
|
elsif subcommand == 'clone'
|
|
14
21
|
Gistim::Clone.clone(ARGV[1], clone_directory: ARGV[2])
|
|
22
|
+
elsif subcommand == 'clone'
|
|
23
|
+
Gistim::Clone.clone(ARGV[1], clone_directory: ARGV[2])
|
|
15
24
|
elsif subcommand == 'create'
|
|
16
25
|
create = Gistim::Create.new(alias_name: ARGV[1]).implement
|
|
17
|
-
puts "#{create.directory}"
|
|
26
|
+
puts "directory: #{create.directory}"
|
|
18
27
|
elsif ['list', 'history'].include? subcommand
|
|
19
28
|
require 'json'
|
|
20
29
|
|
data/gistim.gemspec
CHANGED
|
@@ -21,7 +21,7 @@ Gem::Specification.new do |spec|
|
|
|
21
21
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
|
22
22
|
spec.require_paths = ["lib"]
|
|
23
23
|
|
|
24
|
-
spec.
|
|
24
|
+
spec.add_dependency "gist", "~> 5"
|
|
25
25
|
|
|
26
26
|
spec.add_development_dependency "bundler", "~> 1.16"
|
|
27
27
|
spec.add_development_dependency "rake", "~> 10.0"
|
data/lib/gistim/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: gistim
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Yumainaura
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2018-08-
|
|
11
|
+
date: 2018-08-20 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: gist
|
|
@@ -17,7 +17,7 @@ dependencies:
|
|
|
17
17
|
- - "~>"
|
|
18
18
|
- !ruby/object:Gem::Version
|
|
19
19
|
version: '5'
|
|
20
|
-
type: :
|
|
20
|
+
type: :runtime
|
|
21
21
|
prerelease: false
|
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
|
23
23
|
requirements:
|
|
@@ -88,7 +88,7 @@ executables:
|
|
|
88
88
|
extensions: []
|
|
89
89
|
extra_rdoc_files: []
|
|
90
90
|
files:
|
|
91
|
-
- "
|
|
91
|
+
- "+x"
|
|
92
92
|
- ".github.url"
|
|
93
93
|
- ".gitignore"
|
|
94
94
|
- ".rspec"
|
|
@@ -101,6 +101,7 @@ files:
|
|
|
101
101
|
- README.md
|
|
102
102
|
- Rakefile
|
|
103
103
|
- bin/console
|
|
104
|
+
- bin/gistimnow
|
|
104
105
|
- bin/setup
|
|
105
106
|
- exe/gistim
|
|
106
107
|
- gistim.gemspec
|
data/.gistim.tmp
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
Hello gist!
|