gitup 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (6) hide show
  1. data/README.markdown +49 -0
  2. data/VERSION +1 -1
  3. data/gitup.gemspec +4 -4
  4. data/lib/gitup.rb +10 -4
  5. metadata +6 -6
  6. data/README.rdoc +0 -32
data/README.markdown ADDED
@@ -0,0 +1,49 @@
1
+ # Gitup
2
+
3
+ We want our team members to be working in their own branches locally and
4
+ push to origin/master every once in a while. Gitup is a tool to make that
5
+ easier and avoid a lot of unnecessary conflicts during that time.
6
+
7
+ This gem is developed for use on Mac OS X, but should work on any *nix type system.
8
+ There is a port for Windows using Python developed by [eriik](https://github.com/eriik/gitup-py)
9
+
10
+ ## Installation
11
+
12
+ sudo gem install gitup
13
+
14
+ in your console should do it. You need git installed locally
15
+ and added to your path (which you probably already have).
16
+
17
+
18
+ ## Usage
19
+
20
+ The gem has two basic functions, 'gitup' and 'gitdown'. Both should be added automatically to your path
21
+ when you install the gem.
22
+
23
+ Let's say you clone a new project in Git:
24
+
25
+ git clone git@example.com:repository.git
26
+
27
+ Then you check out your local branch, since working directly in the
28
+ master branch usually gives you a lot of conflicts if you are
29
+ more than one working on the project:
30
+
31
+ git checkout -b new_feature
32
+
33
+ Now whenever you need to update your branch from the origin/master repository
34
+ you could just run the following command:
35
+
36
+ gitdown
37
+
38
+ Or when you want to push your changes to the server:
39
+
40
+ gitup
41
+
42
+ Easy enough?
43
+
44
+ ## Copyright
45
+
46
+ This was developed by David Svensson of [Standout solutions](http://standout.se/ "Ruby on Rails developers in Växjö, Sweden") and
47
+ you could use it in any way you wish. A link to our webpage or a reference to who created it would be appreciated, though.
48
+ Happy gitup-ing! :)
49
+
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.1
1
+ 0.0.2
data/gitup.gemspec CHANGED
@@ -5,24 +5,24 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{gitup}
8
- s.version = "0.0.1"
8
+ s.version = "0.0.2"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["David Svensson"]
12
- s.date = %q{2010-11-30}
12
+ s.date = %q{2010-12-04}
13
13
  s.description = %q{Easily push and pull from remote repositories without running into conflicts.}
14
14
  s.email = %q{david@standout.se}
15
15
  s.executables = ["gitdown", "gitup"]
16
16
  s.extra_rdoc_files = [
17
17
  "LICENSE.txt",
18
- "README.rdoc"
18
+ "README.markdown"
19
19
  ]
20
20
  s.files = [
21
21
  ".document",
22
22
  "Gemfile",
23
23
  "Gemfile.lock",
24
24
  "LICENSE.txt",
25
- "README.rdoc",
25
+ "README.markdown",
26
26
  "Rakefile",
27
27
  "VERSION",
28
28
  "bin/gitdown",
data/lib/gitup.rb CHANGED
@@ -66,11 +66,17 @@ class Gitup
66
66
 
67
67
  def self.run_gitup_commands(branch)
68
68
  puts "Branch: #{branch}"
69
- system "git checkout master"
70
- system "git merge #{branch}"
69
+ unless branch == 'master'
70
+ system "git checkout master"
71
+ system "git merge #{branch}"
72
+ end
71
73
  system "git push origin master"
72
- system "git checkout #{branch}"
73
- system "git rebase master"
74
+ unless branch == 'master'
75
+ system "git checkout #{branch}"
76
+ system "git rebase master"
77
+ else
78
+ puts "You should really consider doing development locally in a branch that is not the master branch."
79
+ end
74
80
  end
75
81
 
76
82
  def self.run_gitdown_commands(branch)
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gitup
3
3
  version: !ruby/object:Gem::Version
4
- hash: 29
4
+ hash: 27
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 1
10
- version: 0.0.1
9
+ - 2
10
+ version: 0.0.2
11
11
  platform: ruby
12
12
  authors:
13
13
  - David Svensson
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-11-30 00:00:00 +01:00
18
+ date: 2010-12-04 00:00:00 +01:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency
@@ -87,13 +87,13 @@ extensions: []
87
87
 
88
88
  extra_rdoc_files:
89
89
  - LICENSE.txt
90
- - README.rdoc
90
+ - README.markdown
91
91
  files:
92
92
  - .document
93
93
  - Gemfile
94
94
  - Gemfile.lock
95
95
  - LICENSE.txt
96
- - README.rdoc
96
+ - README.markdown
97
97
  - Rakefile
98
98
  - VERSION
99
99
  - bin/gitdown
data/README.rdoc DELETED
@@ -1,32 +0,0 @@
1
- = Gitup
2
-
3
- We want our team members to be working in their own branches locally and
4
- push to origin/master every once in a while. Gitup is a tool to make that
5
- easier and avoid a lot of unnecessary conflicts during that time.
6
-
7
- == Installation
8
-
9
- 'sudo gem install gitup' in your console should do it. You need git installed locally
10
- and added to your path (which you probably already have).
11
-
12
- == Usage
13
-
14
- gitup to sync your changes upstream to master repository
15
- gitdown to get changes from
16
-
17
-
18
- == Contributing to gitup
19
-
20
- * Check out the latest master to make sure the feature hasn't been implemented or the bug hasn't been fixed yet
21
- * Check out the issue tracker to make sure someone already hasn't requested it and/or contributed it
22
- * Fork the project
23
- * Start a feature/bugfix branch
24
- * Commit and push until you are happy with your contribution
25
- * Make sure to add tests for it. This is important so I don't break it in a future version unintentionally.
26
- * Please try not to mess with the Rakefile, version, or history. If you want to have your own version, or is otherwise necessary, that is fine, but please isolate to its own commit so I can cherry-pick around it.
27
-
28
- == Copyright
29
-
30
- Copyright (c) 2010 David Svensson. See LICENSE.txt for
31
- further details.
32
-