In: , ,
On: 2013 / 04 / 24
Shorter URL for this post: http://ozh.in/w9

As you might know, YOURLS development is now hosted on Github. It's now easy to download the current development snapshot, since Github provides an archive/master.zip.

But not so long ago, YOURLS dev was hosted on Google Code, where there is no such convenient way to download the current SVN trunk as a .zip archive. To generate "nightly builds", I wrote this little script:

  1. #!/bin/bash
  2. # Simple bash script to generate YOURLS nightly builds
  3.  
  4. # Export in a year-month-day directory
  5. PWD="/home/ozh/yourls.org/nightly-builds"
  6. BUILD=$(date +%Y-%m-%d)
  7. svn -q export http://yourls.googlecode.com/svn/trunk/ $PWD/$BUILD
  8.  
  9. # Make package and remove dir
  10. cd $PWD
  11. zip -r -q yourls-$BUILD.zip $BUILD
  12. rm -rf $BUILD
  13.  
  14. # Remove old (>7 days) builds
  15. find $PWD/*zip -mtime +7 -exec rm {} \;

Now you just need to add the script to your cron jobs and call it every night.

Shorter URL

Want to share or tweet this post? Please use this short URL: http://ozh.in/w9

Metastuff

This entry "How-to: generate nightly builds from a SVN repository" was posted on 24/04/2013 at 6:51 pm and is tagged with , ,
Watch this discussion : Comments RSS 2.0.

No Comment yet

Leave a Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>
Gravatars: Curious about the little images next to each commenter's name ? Go to Gravatar and sign for a free account
Spam: Various spam plugins may be activated. I'll put pins in a Voodoo doll if you spam me.

Read more ?