dev_tasks 0.0.7 → 0.0.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/build.rb +1 -1
- data/lib/commands.rb +10 -5
- data/lib/commit.rb +6 -1
- data/lib/dev_tasks.rb +1 -2
- metadata +1 -15
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b1eb0298447cf2d3ed26a7194bda05d4737a3ce1
|
4
|
+
data.tar.gz: dc69f8cc9fd87ac031909d457c7f2ce170c394ba
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bd5f4b1f9796020a3d47da88474d6dab6b8c7fb0ae16a15756da2e5b80d4c68d528ba0fcb48dbc1af1715fa732b32bbc5dae209aad94a15bdf6d6cfe29b2caee
|
7
|
+
data.tar.gz: 681359bd70692db656d3e462a1ea05794027d6441281b69313123272b560f041a5fa6acdab6fef64c5412fdd270002b72afd64244f6a370c451f5391b498b0e8
|
data/lib/build.rb
CHANGED
data/lib/commands.rb
CHANGED
@@ -16,12 +16,17 @@ class Commands < Hash
|
|
16
16
|
def execute_command command
|
17
17
|
puts Color.yellow + command + Color.clear
|
18
18
|
puts " "
|
19
|
-
puts `#{command}`
|
20
19
|
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
20
|
+
if command.include?('<%') && command.include?('%>')
|
21
|
+
ruby = command.gsub("<%","").gsub("%>","")
|
22
|
+
eval(ruby)
|
23
|
+
else
|
24
|
+
puts `#{command}`
|
25
|
+
if $? != 0
|
26
|
+
raise Color.bright_yellow + "`" + Color.green + command + Color.bright_yellow + "`" + Color.clear +
|
27
|
+
" has exit code " + $?.to_s
|
28
|
+
end
|
29
|
+
end
|
25
30
|
end
|
26
31
|
|
27
32
|
def show
|
data/lib/commit.rb
CHANGED
@@ -3,7 +3,12 @@ class Commit < Array
|
|
3
3
|
def initialize
|
4
4
|
if(Dir.exists?(".git"))
|
5
5
|
if(!`git status`.include?('nothing to commit') || `git status`.include?('untracked files present'))
|
6
|
-
|
6
|
+
if(File.exists?('commit.message') && File.read('commit.message').gsub(/\s+/, "").length > 0)
|
7
|
+
self.add "git commit -a -v -m \"#{File.read('commit.message')}\""
|
8
|
+
self.add "<%File.open('commit.message','w'){|f|f.write('')}%>"
|
9
|
+
else
|
10
|
+
self.add 'git commit -a -v -m "commit all"'
|
11
|
+
end
|
7
12
|
end
|
8
13
|
end
|
9
14
|
end
|
data/lib/dev_tasks.rb
CHANGED
@@ -1,6 +1,5 @@
|
|
1
1
|
require 'semver'
|
2
2
|
require 'rake'
|
3
|
-
require 'awesome_print'
|
4
3
|
require 'rake/clean'
|
5
4
|
include Rake::DSL
|
6
5
|
|
@@ -71,7 +70,7 @@ end
|
|
71
70
|
DEV_TASKS=DevTasks.new
|
72
71
|
|
73
72
|
desc 'displays dev_task commands'
|
74
|
-
task :
|
73
|
+
task :info do
|
75
74
|
puts "DEV_TASKS.commands"
|
76
75
|
puts " "
|
77
76
|
puts DEV_TASKS.commands.show
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dev_tasks
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Lou Parslow
|
@@ -52,20 +52,6 @@ dependencies:
|
|
52
52
|
- - '>='
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '0'
|
55
|
-
- !ruby/object:Gem::Dependency
|
56
|
-
name: awesome_print
|
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
55
|
- !ruby/object:Gem::Dependency
|
70
56
|
name: rspec
|
71
57
|
requirement: !ruby/object:Gem::Requirement
|