dev 1.0.102 → 1.0.103
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.
- data/lib/dev/Defaults.rb +14 -0
- data/lib/dev/Project.rb +2 -5
- metadata +2 -1
data/lib/dev/Defaults.rb
ADDED
@@ -0,0 +1,14 @@
|
|
1
|
+
module Dev
|
2
|
+
class Defaults
|
3
|
+
attr_accessor :project
|
4
|
+
|
5
|
+
def get_default_value(key)
|
6
|
+
return get_default_value_src_glob if key=="src_glob"
|
7
|
+
end
|
8
|
+
|
9
|
+
def get_default_value_src_glob
|
10
|
+
value="**/{*.{rb,feature,spec,cs,c,cpp,h,hpp,csproj,vcproj,snk,vcxproj,sln,filters,xaml,xml,resx,settings,txt,png,bmp,ico},Jamfile,.semver,Gemfile,README,LICENSE}"
|
11
|
+
return value
|
12
|
+
end
|
13
|
+
end # class Defaults
|
14
|
+
end # module Dev
|
data/lib/dev/Project.rb
CHANGED
@@ -289,12 +289,9 @@ class Project < Hash
|
|
289
289
|
value="#{Dev::Environment.dev_root}" if key=="dev_root"
|
290
290
|
value="C#" if key=="type"
|
291
291
|
|
292
|
+
defaults = Defaults.new
|
293
|
+
value=defaults.get_default_value(key) if key=="src_glob"
|
292
294
|
|
293
|
-
value="**/*.{rb,feature,semver}" if key=="src_glob"
|
294
|
-
value="**/*.{cs,csproj,sln,xaml,xml,rb,resx,settings,feature,semver,snk,txt,png,bmp,ico}" if key=="src_glob" && self[:type]=="C#"
|
295
|
-
value="**/{*.{c,cpp,h,hpp,semver,vcproj,vcxproj,filters,sln,txt,rb},Jamfile}" if key=="src_glob" && (self[:type]=="C++" || self[:type]=="c++" || self[:type]=="cpp")
|
296
|
-
value="**/*.{rb,feature,semver}" if key=="src_glob" && self[:type]=="ruby"
|
297
|
-
value="**/*.{rb,feature,gemspec,semver}" if key=="src_glob" && self[:type]=="gem"
|
298
295
|
value=loc_total if key=="loc"
|
299
296
|
value="svn" if key=="scm_type" && File.exists?(".svn")
|
300
297
|
value="git" if key=="scm_type" && File.exists?(".git")
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dev
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.103
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -149,6 +149,7 @@ files:
|
|
149
149
|
- LICENSE
|
150
150
|
- README
|
151
151
|
- lib/dev/BoostBuild.rb
|
152
|
+
- lib/dev/Defaults.rb
|
152
153
|
- lib/dev/Dep.rb
|
153
154
|
- lib/dev/Environment.rb
|
154
155
|
- lib/dev/Hash.rb
|