-
require выражения
-
include выражения
-
определение классов и модулей
-
основная часть программы
-
код для тестирования
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
source :rubygems | |
gem 'rspec' | |
gem 'capybara' | |
gem 'json' |
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
source 'http://rubygems.org' | |
gem 'i18n' | |
gem 'activesupport', '>= 2.3.5' | |
gem 'octokit', '~> 0.6.0' |
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: Sign up | |
Scenario: Successful sign up | |
Given I have chosen to sign up | |
When I sign up with valid details | |
Then I should receive a confirmation email | |
And I should see a personalized greeting message | |
Scenario: Duplicate email | |
Given I have chosen to sign up |
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 | |
PASSWORD = "123456" | |
USERNAME = "user%d" | |
(1..3).each do |i| | |
user = USERNAME % i | |
puts `/usr/sbin/useradd --groups rvm #{user}` | |
puts `echo -e "#{PASSWORD}\n#{PASSWORD}" | (/usr/bin/passwd --stdin #{user})` |
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 | |
# copy members from one team to other | |
require 'json' | |
source_team_id = | |
target_team_id = | |
token = '' |
Basics
- 2 blog posts
- 2 pull requests to OS projects
- Complete Berkeley's CS169.1x: Software as a Service
- https://github.com/fs/library/tree/master/The%20Agile%20Samurai
- Learn and follow style guides http://guides.flatstack.com/best-practices/README.html
- https://learn.thoughtbot.com/heroku: Beginning Heroku
- https://learn.thoughtbot.com/unix: Beginning unix
- https://learn.thoughtbot.com/sql: Beginning Postgres
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
// | |
// InAppManager.swift | |
// | |
// Created by Ellina Kuznetcova on 12/10/2016. | |
// Copyright © 2016 Flatstack. All rights reserved. | |
// | |
import Foundation | |
import StoreKit |
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/bash | |
# Force outbound traffic through the attached floating IP | |
NET_INT="eth0" | |
CURL_TIMEOUT=3 | |
echo -n "Setting floating IP as the default gateway: " | |
# Check there's a floating IP attached to this droplet | |
if [ "$(curl -s --connect-timeout $CURL_TIMEOUT http://169.254.169.254/metadata/v1/floating_ip/ipv4/active)" != "true" ]; then |
OlderNewer