Re-Written from the ground-up for use with Git. I imagined it a “local” version of GitHub for your repositories
I’m working on this section :)
-
Commits for a repository
-
History and Blame for a file
-
Multi-View
-
Command-Line Syncer
-
Admin and Post-Recieve Hooks
-
Dashboard
-
Authentication
-
Git Post-Push sync script
-
Tests
First clone the project with
git clone git://github.com/drcapulet/warehouse.git
Then, use Bundler to manage and vendoring Gem dependencies. To install the Gems, run:
gem install bundler && bundle install
After, check to make sure you have Pygments, (the library we use to highlight source code), if not, install using instructions from the Pygments
Then, make sure you have the database created and load in the schema
rake db:schema:load
Finally, add in a new repository, and run
rake warehouse:sync
And then startup the server and view :)
Installation for production use is almost the same like for the development environment. Be aware, that domain has been configured with Passenger or Mongrell support (FastCGI is strongly NOT recommended). If you’re running Warehouse on your server under some domain, first go inside the directory, where application will be installed. In most cases directory will have the name of the domain:
[server]$ cd ~/subdomain.yourdomain.com/
Then, clone the project:
[server]$ git clone git://github.com/drcapulet/warehouse.git [server]$ mv warehouse/* ~/subdomain.yourdomain.com/ [server]$ rm -rf warehouse
Install dependencies:
[server]$ gem install bundler && bundle install
Check out if you have the pygments library installed. This library is neccessary for source code highlighting. In production you probably do not want to use sqlite, instead MySQL is preferable. To use MySQL type this inside the RAILS_ROOT directory:
[server]$ rm config/database.yml [server]$ cp config/database.mysql_sample.yml config/database.yml
Then, make sure you have the database created and loaded in the schema. Again, from the RAILS_ROOT directory:
[server]$ RAILS_ENV=production rake db:schema:load
Before starting the server make sure you properly configured your domain name in the RAILS_ROOT/config/warehouse.yml, otherwise application just will not start. Find the section and configure it properly:
production: host: http://subdomain.yourdomain.com/
Add in a new repository, and run:
[server]$ RAILS_ENV=production rake warehouse:sync
Apparently, you’ll cause an exception with the repository sync error. Don’t worry, start the server and go to your domain in the browser window. Register new user, login and add new repository, where path to the repository will be something like this: /home/USERNAME/repositories/super_secret_project. After that, go back to the console prompt and type:
[server]$ RAILS_ENV=production rake warehouse:sync[/home/USERNAME/repositories/super_secret_project]
Your initial repository should to be synchronized properly now. Login to warehouse and enjoy!
New Repository:
Repository Browsing:
File Viewing:
File Blame:
Commits:
Commit:
Hooks:
Multi-View:
I’d love your help, or your bug reports :) Some guides (like for hooks) will be added soon on how to contribute those specific items.
Copyright © 2011 Alex Coomans
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.