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
| <%= page_title 'hub.select_documents.title_photo_documents' %> | |
| <% content_for :feedback_source, 'SELECT_DOCUMENTS_PAGE_PHOTO_DOCUMENTS' %> | |
| <div id="no-documents-message" class="visually-hidden" aria-live="assertive" data-no-documents-message="<%= h t('hub.select_documents.no_documents_message') %>"></div> | |
| <div class="grid-row"> | |
| <div class="column-two-thirds"> | |
| <h1 class="heading-large"><%= t 'hub.select_documents.title_photo_documents' %></h1> | |
| <p><%= t 'hub.select_documents.sub_heading' %></p> | |
| <% if flash[:errors] %> |
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
| Vagrant::Config.run do |config| | |
| config.vm.box = "python" | |
| config.vm.box_url = "http://dl.dropbox.com/u/29645873/vagrants/python.box" | |
| config.ssh.forward_x11 = true | |
| config.vm.forward_port 8888, 8888 | |
| end |
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
| require 'airport' | |
| describe Airport do | |
| let(:plane) { Plane.new } | |
| context "landing" do | |
| it { is_expected.to respond_to(:to_land).with(1).argument} | |
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
| require './lib/send_reset_email' | |
| describe SendResetEmail do | |
| let(:user) { double :user, password_token: '4nknkj34nkj23n4j32', email: | |
| "user@example.com" } | |
| let(:email_client) { double :email_client, post: :recovery_message } | |
| subject { SendResetEmail } | |
| it 'passes a recovery message to an email client' do |
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
| require 'mailgun' | |
| class SendResetEmail | |
| CLIENT = RestClient | |
| def self.call user | |
| CLIENT.post "https://api:#{ENV['mailgun_api']}"\ | |
| "@api.mailgun.net/v3/sandbox8a194822b88f467e809f01cbd74859f3.mailgun.org/messages", email_contents(user) | |
| end |
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
| module Inject_challenge | |
| def recursive_inject start_with=false &block | |
| unless start_with | |
| start_with = self.first | |
| end | |
| if self.count == 1 | |
| self.last | |
| else |
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
| var spreadsheetURL = { | |
| "sheet1": "https://spreadsheets.google.com/feeds/list/1O82vKugVL7nW60U3NLLtJMG_4nhU8E3UpCgTfzRrD6E/od6/public/values?alt=json" | |
| }; | |
| var spreadsheetData = { | |
| 'sheet1':[] | |
| }; | |
| //ajax request from google sheet | |
| var dataFetch = function(url) { | |
| $.ajax({ | |
| url: url, |
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
| # !/bin/env/python | |
| # -*- coding: utf-8 -*- | |
| import os | |
| import sys | |
| import xlrd | |
| import csv | |
| filename = sys.argv[1] |
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
| #!/usr/bin/env python | |
| # -*- coding: utf-8 -*- | |
| import urllib | |
| import requests | |
| url = "https://www.google.co.uk" | |
| queries = [] | |
| for query in queries: |
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
| # !/usr/bin/python | |
| # coding: utf-8 | |
| import os | |
| import sys | |
| import json | |
| import requests | |
| import csv | |
| api = "http://api.ratings.food.gov.uk/Establishments/" |
NewerOlder