Skip to content

Instantly share code, notes, and snippets.

View limamedeiros's full-sized avatar
☺️

Vanessa Medeiros limamedeiros

☺️
  • Thoughtworks
  • Brazil
View GitHub Profile
@limamedeiros
limamedeiros / Models.swift
Created August 10, 2017 19:49 — forked from zats/Models.swift
Init based Storyboard View Controller Instantiation
import Foundation
// Some clearly non-NSObject-based models:
enum Coconut: String {
case small, medium, large
}
struct Tomato {
static var red = Tomato(color: #colorLiteral(red: 0.7490196078, green: 0.09803921569, blue: 0.02352941176, alpha: 1))
@limamedeiros
limamedeiros / feedly_export_saved_for_later.js
Last active May 24, 2017 21:37 — forked from ShockwaveNN/feedly_export_saved_for_later
Working script for latest feedly redising. Drop support of `time` field, no longer avaible (or I din't found it)
function loadJQuery(){
script = document.createElement('script');
script.setAttribute('src', '//code.jquery.com/jquery-2.1.3.js');
script.setAttribute('type', 'text/javascript');
script.onload = loadSaveAs;
document.getElementsByTagName('head')[0].appendChild(script);
}
function loadSaveAs(){
saveAsScript = document.createElement('script');
@limamedeiros
limamedeiros / gist:ecdb439f79b1d19524f4
Last active August 29, 2015 14:10
Opens Safari's current tab in a new private window and closes the tab. If a private window already exists, then opens the current tab in that window.
tell application "Safari"
activate
set theURL to the URL of the current tab of the front window
close current tab of front window
end tell
tell application "Safari"
activate
set theWindow to false
repeat with w in (every window whose visible is true)
@limamedeiros
limamedeiros / gist:7a5bf310f4ce66b2f1cb
Last active August 29, 2015 14:09
Opens Safari's current tab in Private Browsing
tell application "Safari"
activate
set theURL to the URL of the current tab of the front window
close current tab of window 1
end tell
tell application "System Events"
tell process "Safari"
tell menu bar 1
click menu bar item "File"