Agreed, I don't like --force. Let's use tags and use git to remove the release tag and assign it to a new point.
http://www.kernel.org/pub/software/scm/git/docs/git-tag.html --Michael On Tue, Apr 20, 2010 at 10:57 AM, Markus Roberts <[email protected]> wrote: > This is risky code, in that it does no checking to see if one step worked > before plunging on to the next. It might make sense to use $CHILD_STATUS > liberally or to use something like the Git module (see refactoring_tools.rb > in my tools_for_refactoring_puppet branch). Also, "git add *" could easily > sweep up things we don't want unless the output dir is brand new & newly > populated. And finally the "DISABLED FOR NOW" comment looks to be out of > date. > > On Tue, Apr 20, 2010 at 3:32 AM, James Turnbull <[email protected]> > wrote: >> >> Signed-off-by: James Turnbull <[email protected]> >> --- >> Rakefile | 18 ++++++++++++++---- >> 1 files changed, 14 insertions(+), 4 deletions(-) >> >> diff --git a/Rakefile b/Rakefile >> index 71f1cca..31a36dd 100644 >> --- a/Rakefile >> +++ b/Rakefile >> @@ -119,10 +119,20 @@ end >> # Puppet Labs Only: >> # DISABLED FOR NOW, not the right location >> >> -#desc "Release the documentation (Puppet Labs Only)" >> -#task :release do >> -# sh "rsync -e ssh -avz output/ >> [email protected]:/var/www/docs/html" >> -#end >> +desc "Release the documentation (Puppet Labs Only)" >> +task :release do >> + branch = "release" >> + sh "git checkout master" >> + sh "git branch -f #{branch}" >> + sh "git checkout #{branch}" >> + Rake::Task['generate'].invoke >> + FileUtils.cd 'output' >> + sh "git add *" >> + sh "git commit -a -m 'Released Puppet Documentation'" >> + sh "git branch -D -r origin/#{branch}" >> + sh "git push --force origin #{branch}" >> + sh "git checkout master" >> +end >> >> #require 'spec/rake/spectask' >> #Spec::Rake::SpecTask.new(:spec) do |spec| >> -- >> 1.6.6.1 >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Puppet Developers" group. >> To post to this group, send email to [email protected]. >> To unsubscribe from this group, send email to >> [email protected]. >> For more options, visit this group at >> http://groups.google.com/group/puppet-dev?hl=en. >> > > > > -- > ----------------------------------------------------------- > The power of accurate observation is > commonly called cynicism by those > who have not got it. ~George Bernard Shaw > ------------------------------------------------------------ > > -- > You received this message because you are subscribed to the Google Groups > "Puppet Developers" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/puppet-dev?hl=en. > -- You received this message because you are subscribed to the Google Groups "Puppet Developers" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/puppet-dev?hl=en.
