This file contains hidden or 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
# this file should live in the same directory as the JSON grade output | |
require 'json' | |
output = File.open( "output.txt","w" ) | |
Dir.foreach('.') do |item| | |
next if item == '.' || item == '..' || item.include?('json') == false | |
file = File.read(item) | |
score = JSON.parse(file)['summary_line'] | |
output.write("#{item} - #{score}\n") | |
puts "#{item} #{score}" |
This file contains hidden or 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
# edit the project name and any feature specs if they're being copied in | |
project_name=photogram_golden_seven | |
mkdir ${project_name}_grades | |
cd $project_name | |
for branch in $(git for-each-ref --format='%(refname)' refs/remotes/); do | |
short_name=${branch/refs\/remotes\/origin\//""} | |
echo $short_name | |
git add -A |
- Create a branch with
git branch [your_branch_name]
- Checkout the branch with
git checkout [your_branch_name]
- Publish your branch with
git push origin [your_branch_name]
- Do some work, commit your changes
- When your branch is done, checkout master with
git checkout master
- Pull down any changes from master with
git pull
- Checkout your branch again and make sure it is up to date with master using
git merge master
- If there are any conflicts, fix them. If not, you may need to exit the Vim text editor using
:wq
- Fork the repo that you're working on into your own account.
- Clone down the fork
- Create a new branch in the fork using
git branch [branch_name]
replacing[branch_name]
with a short phrase describing the feature your'e working on - Check the current status of your branches by using
git branch
. You should see all the branches you have access to. Your current branch will have an*
next to it - Check out the new branch using
git checkout [branch_name]
- Make your changes in the code
- Add and commit your changes
- Pull down any changes from the original repo:
- Add the original repo as an upstream remote with
git remote add upstream https://github.com/ORIGINAL_OWNER/ORIGINAL_REPOSITORY.git
. Make sure to use the actual owner and repository names. - Pull changes into your branch from the upstream remote with
git pull upstream master
Orange and Blue
Night and Day
Read more/less
Sliding and hiding
- What is Rails? What problem is it solving for us?
- How would you describe terminal?
- What is the purpose of the application layout file?
- What is the purpose of each of the following parts of a Rails request:
- the routes file
- the controller
- the action
- the view
NewerOlder