This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
## ======================================================== | |
## Build Agility, as per the tutorial | |
## ======================================================== | |
## run this script from a fresh directory. | |
## It will unload the heplers here, and build the app in the agility | |
## It is meant to be run in stages, where it runs into an 'exit' | |
## just comment over, and start again for the next step | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
## Shows model relationships on the given RoR app. | |
## add --help | |
## ?? add --belongs to filter out only given macros | |
## put message 'nothing relates' if models but no associations found. | |
puts ARGV | |
Dir.chdir( ARGV.shift || '.' ) do |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
## Shows model relationships on the given RoR app. | |
puts ARGV | |
Dir.chdir( ARGV.shift || '.' ) do | |
require 'config/environment' | |
finder = 'find app/models -type f -name \*.rb -print0 |xargs -0 -- grep ActiveRecord::Base |sort' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Pointer to the patch files, downloaded from github | |
SRC=~/Clones/hobocookbook/public/patches/agility/ | |
# The following code is interspersed with the headings from | |
# the tutorial. Where there is a generator to run, I simply | |
# run the generator. Otherwise, I run the patch you give. | |
# This will allow for the generators to generate, and the patches to | |
# add the code, as needed. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Feature: The Models | |
As a practicing Hobo, | |
I want to lay out the models | |
So I can achieve these stated goals: | |
* Track multiple projects | |
* Each having a collection of stories | |
* Stories are just a brief chunk of text | |
* A story can be assigned a current status and a set of outstanding tasks | |
* Tasks can be assigned to users |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Feature: Removing Actions | |
As a practising Hobo, | |
I want to disable unwanted routes | |
We only really want to see tasks listed against stories and users. | |
We want to add stories within projects, and tasks within stories. | |
Scenario Outline: User experience | |
Given I am logged in as <User> | |
And the following Project records exist: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Feature: Permissions | |
As a practical Hobo, | |
I want to specify permissions | |
* Only administrators can create, edit and delete Projects | |
* Stories and Tasks ( and TaskAssignments) are open to change by all signed up users. | |
* Guests are only able to view | |
* prevent Stories being moved from its original Project |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# --- | |
# location of patches | |
P=../patches/agility/ | |
rm -fr agility | |
hobo agility | |
cd agility |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
## Build Agility | |
rm -fr agility | |
hobo agility | |
cd agility | |
# add db:seeds rake task | |
cat <<__PATCH |patch -p1 | |
patch rails for db:seeds |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Initialize hobo | |
$ rm -fr agility | |
$ hobo agility | |
$ cd agility | |
{: .bash} | |
### add db:seeds rake task | |
{: .bash} | |
::: ./lib/tasks/database.rake | |
new file mode 100644 | |
@@ -0,0 +1,15 @@ |
OlderNewer