v2gpti 1.0.0 → 1.0.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 9c40ac095248137c3bf4ac4a8234465ca06918c0
4
- data.tar.gz: 6c6004549bc126677b84f527ac086a4d10ffbb82
3
+ metadata.gz: 49175127d5a30c7330da908dcfbf8577d17402c5
4
+ data.tar.gz: 19e6bb05f2f38a6cde8b926f8d006a106a611db1
5
5
  SHA512:
6
- metadata.gz: 0d56c263e151e31ab44e5e6c516c7f290eb21befdfca4e786cfc3d3e64d13d3b5281b3b6f04857f6fdfc6d0c8720894deac0a9567082899a7c4efd0c1fc00a9a
7
- data.tar.gz: 20be0ff915cb2e094f657c1c6eeb4bb5c649c41eede36eb350cbe0d445ded969b0f58d4d92eb3098eff322c09e8b4846586a067a7fb576def0fda8635fb83355
6
+ metadata.gz: e82162ebf3cffb096ca470e3f51a574b2fd52ddd906a1d3baef46b39a3787f3e71f13f6859733e3796810b9e82582d30117a34797fad7e66fb1252ae9769c9cd
7
+ data.tar.gz: b4fb78d07494dc71aec5425c465519efc5b5628b78a698ed95f1e4015b958ad5c959c176866ae8a2ecfd39f060cd423dda69c2d368cecf835855b599afde707a
@@ -33,13 +33,6 @@ class GitPivotalTrackerIntegration::Command::Base
33
33
  def initialize
34
34
  self.start_logging
35
35
  self.check_version
36
-
37
- git_global_push_default = (GitPivotalTrackerIntegration::Util::Shell.exec "git config --global push.default").chomp
38
- if git_global_push_default != "simple"
39
- puts "git config --global push.default simple"
40
- puts GitPivotalTrackerIntegration::Util::Shell.exec "git config --global push.default simple"
41
- end
42
-
43
36
  @repository_root = GitPivotalTrackerIntegration::Util::Git.repository_root
44
37
  @configuration = GitPivotalTrackerIntegration::Command::Configuration.new
45
38
  @toggl = Toggl.new
@@ -55,11 +48,7 @@ class GitPivotalTrackerIntegration::Command::Base
55
48
  @toggl.create_time_entry(parameters(configuration, time_spent))
56
49
  end
57
50
  def start_logging
58
- $LOG = Logger.new("#{logger_filename}", 'weekly')
59
- end
60
-
61
- def logger_filename
62
- return "#{Dir.home}/.v2gpti_local.log"
51
+ $LOG = Logger.new("#{Dir.home}/.v2gpti_local.log", 'weekly')
63
52
  end
64
53
 
65
54
  def check_version
@@ -80,7 +69,6 @@ class GitPivotalTrackerIntegration::Command::Base
80
69
  raise NotImplementedError
81
70
  end
82
71
 
83
- # Toggl keys
84
72
  # name : The name of the task (string, required, unique in project)
85
73
  # pid : project ID for the task (integer, required)
86
74
  # wid : workspace ID, where the task will be saved (integer, project's workspace id is used when not supplied)
@@ -36,8 +36,6 @@ class GitPivotalTrackerIntegration::Command::Finish < GitPivotalTrackerIntegrati
36
36
  $LOG.debug("configuration:#{@configuration}")
37
37
  $LOG.debug("project:#{@project}")
38
38
  $LOG.debug("story:#{@configuration.story(@project)}")
39
- memm = PivotalTracker::Membership.all(@project)
40
- self.commit_new_build
41
39
  time_spent = ""
42
40
  while 1
43
41
  time_spent = ask("How much time did you spend on this task? (example: 15m, 2.5h)")
@@ -51,27 +49,5 @@ class GitPivotalTrackerIntegration::Command::Finish < GitPivotalTrackerIntegrati
51
49
  end
52
50
 
53
51
 
54
- def commit_new_build
55
- # Update version and build numbers
56
- build_number = Time.now.utc.strftime("%y%m%d-%H%M")
57
52
 
58
- puts "build_number:#{build_number}"
59
- project_directory = ((GitPivotalTrackerIntegration::Util::Shell.exec 'find . -name "*.xcodeproj" 2>/dev/null').split /\/(?=[^\/]*$)/)[0]
60
- working_directory = (GitPivotalTrackerIntegration::Util::Shell.exec "pwd").chop
61
- puts "working_directory:#{working_directory}*"
62
-
63
- # cd to the project_directory
64
- Dir.chdir(project_directory)
65
-
66
- # set build number and project number in project file
67
- GitPivotalTrackerIntegration::Util::Shell.exec "pwd"
68
- puts GitPivotalTrackerIntegration::Util::Shell.exec "xcrun agvtool new-version -all #{build_number}", false
69
- puts GitPivotalTrackerIntegration::Util::Shell.exec "xcrun agvtool new-marketing-version SNAPSHOT"
70
-
71
- # cd back to the working_directory
72
- Dir.chdir(working_directory)
73
-
74
- # Create a new build commit, push to develop
75
- GitPivotalTrackerIntegration::Util::Git.create_commit( "Update build number to #{build_number}", @configuration.story(@project))
76
- end
77
53
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: v2gpti
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ben Hale
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-06-13 00:00:00.000000000 Z
12
+ date: 2014-06-16 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: highline
@@ -214,7 +214,6 @@ executables:
214
214
  - git-deliver
215
215
  - git-finish
216
216
  - git-release
217
- - git-report
218
217
  - git-start
219
218
  extensions: []
220
219
  extra_rdoc_files: []
@@ -225,7 +224,6 @@ files:
225
224
  - bin/git-deliver
226
225
  - bin/git-finish
227
226
  - bin/git-release
228
- - bin/git-report
229
227
  - bin/git-start
230
228
  - lib/git-pivotal-tracker-integration/command/base.rb
231
229
  - lib/git-pivotal-tracker-integration/command/command.rb
@@ -234,7 +232,6 @@ files:
234
232
  - lib/git-pivotal-tracker-integration/command/finish.rb
235
233
  - lib/git-pivotal-tracker-integration/command/prepare-commit-msg.sh
236
234
  - lib/git-pivotal-tracker-integration/command/release.rb
237
- - lib/git-pivotal-tracker-integration/command/report.rb
238
235
  - lib/git-pivotal-tracker-integration/command/start.rb
239
236
  - lib/git-pivotal-tracker-integration/util/git.rb
240
237
  - lib/git-pivotal-tracker-integration/util/shell.rb
data/bin/git-report DELETED
@@ -1,19 +0,0 @@
1
- #!/usr/bin/env ruby -U
2
- # Git Pivotal Tracker Integration
3
- # Copyright (c) 2013 the original author or authors.
4
- #
5
- # Licensed under the Apache License, Version 2.0 (the "License");
6
- # you may not use this file except in compliance with the License.
7
- # You may obtain a copy of the License at
8
- #
9
- # http://www.apache.org/licenses/LICENSE-2.0
10
- #
11
- # Unless required by applicable law or agreed to in writing, software
12
- # distributed under the License is distributed on an "AS IS" BASIS,
13
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
- # See the License for the specific language governing permissions and
15
- # limitations under the License.
16
-
17
- require 'git-pivotal-tracker-integration/command/report'
18
-
19
- GitPivotalTrackerIntegration::Command::Report.new().run ARGV
@@ -1,64 +0,0 @@
1
- # Git Pivotal Tracker Integration
2
- # Copyright (c) 2013 the original author or authors.
3
- #
4
- # Licensed under the Apache License, Version 2.0 (the "License");
5
- # you may not use this file except in compliance with the License.
6
- # You may obtain a copy of the License at
7
- #
8
- # http://www.apache.org/licenses/LICENSE-2.0
9
- #
10
- # Unless required by applicable law or agreed to in writing, software
11
- # distributed under the License is distributed on an "AS IS" BASIS,
12
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
- # See the License for the specific language governing permissions and
14
- # limitations under the License.
15
-
16
- require 'git-pivotal-tracker-integration/command/base'
17
- require 'git-pivotal-tracker-integration/command/command'
18
- require 'git-pivotal-tracker-integration/util/git'
19
- require 'git-pivotal-tracker-integration/util/story'
20
- require 'git-pivotal-tracker-integration/version-update/gradle'
21
-
22
-
23
- class GitPivotalTrackerIntegration::Command::Report < GitPivotalTrackerIntegration::Command::Base
24
-
25
-
26
- def run(args)
27
-
28
- owned_by = "Jeff Wolski" # hard coded to Jeff Wolski for now
29
-
30
-
31
- $LOG.debug("#{self.class} in project:#{@project.name} pwd:#{(GitPivotalTrackerIntegration::Util::Shell.exec 'pwd').chop} branch:#{GitPivotalTrackerIntegration::Util::Git.branch_name}")
32
- bug_title = nil
33
- if args.length == 1
34
- bug_title = args[0]
35
- end
36
- # puts bug_title
37
- if bug_title.nil? || bug_title.empty?
38
- abort "\nUsage example:\n\n git report \"Issue running deliver command\" \n"
39
- end
40
-
41
- report_note = ""
42
- while (report_note.nil? || report_note.empty?)
43
- report_note = ask("Description of bug:")
44
- end
45
-
46
- current_user = (GitPivotalTrackerIntegration::Util::Shell.exec "git config user.name").chomp
47
- bug_title = "User Reported - #{current_user} - #{bug_title}"
48
- current_user_email = (GitPivotalTrackerIntegration::Util::Shell.exec "git config user.email").chomp
49
- bug_description = "#{current_user_email}\n#{report_note}"
50
-
51
- bug_story = PivotalTracker::Story.new
52
- bug_story.project_id = @project.id
53
- bug_story.owned_by = owned_by
54
- bug_story.story_type = "bug"
55
- bug_story.name = bug_title
56
- bug_story.description = bug_description
57
- bug_story.labels = "userreported"
58
- uploaded_story = bug_story.create
59
- uploaded_story.upload_attachment(self.logger_filename)
60
- end
61
-
62
-
63
-
64
- end