Skip to content

Instantly share code, notes, and snippets.

View jasonsanjose's full-sized avatar

Jason San Jose jasonsanjose

View GitHub Profile
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>CodeMirror: Inline Widget Demo</title>
<link rel="stylesheet" href="http://codemirror.net/lib/codemirror.css">
<script src="http://codemirror.net/lib/codemirror.js"></script>
<script src="http://codemirror.net/mode/javascript/javascript.js"></script>
<script src="http://ajax.aspnetcdn.com/ajax/jshint/r07/jshint.js"></script>
@jasonsanjose
jasonsanjose / README.md
Last active February 16, 2017 08:11
brackets-shell linux debian/ubuntu setup

Choose a directory to download both brackets-shell and brackets git respositories. The following script will setup the repositories and download required dependencies.

wget https://gist.github.com/jasonsanjose/5514813/raw/6215f3b73ff41f51e20bc94a9faa3e453402ce06/setup.sh; chmod +x setup.sh; bash setup.sh; rm setup.sh
@jasonsanjose
jasonsanjose / brackets-ubuntu-setup
Created June 11, 2013 17:56
WIP brackets ubuntu setup
#!/bin/bash
# install git, 7zip
sudo apt-get install -qq --assume-yes git p7zip-full libgtk2.0-dev
# clone brackets-shell
git clone https://github.com/adobe/brackets-shell.git -b jasonsanjose/linux
# run setup
pushd brackets-shell
@jasonsanjose
jasonsanjose / modtimes.out
Created January 14, 2014 19:12
modtimes.out for https://github.com/adobe/brackets/issues/6437. I got the overwrite dialog for ProjectManager.js and this log is captured immediately after it happened.
This file has been truncated, but you can view the full file.
10:31:47 stat64 /Users/jasonsj/Github/brackets/src/LiveDevelopment/Agents/CSSAgent.js 0.000020 Sublime Text
10:31:47 stat64 /Users/jasonsj/Github/brackets/src/LiveDevelopment/Agents/CSSAgent.js 0.000023 Sublime Text
10:31:47 open /Users/jasonsj/Github/brackets/src/LiveDevelopment/Agents/CSSAgent.js 0.000033 Sublime Text
10:31:52 stat64 /Users/jasonsj/Github/brackets/src/LiveDevelopment/Agents/CSSAgent.js 0.000022 Sublime Text
10:31:55 getattrlist ndfifopckmhdkohjeoljlbfnjhekfg/3.9.20.99_0/data/src/autosave_prompt_iframe.js 0.000005 Google Chrom
10:31:55 access ndfifopckmhdkohjeoljlbfnjhekfg/3.9.20.99_0/data/src/autosave_prompt_iframe.js 0.000005 Google Chrom
10:31:55 open ndfifopckmhdkohjeoljlbfnjhekfg/3.9.20.99_0/data/src/autosave_prompt_iframe.js 0.000028 Google Chrom
10:31:57 open Host/com.apple.loginwindow.C48DBEE8-760F-5551-9D11-D1C343E0A374.p
@jasonsanjose
jasonsanjose / ratings.md
Last active August 29, 2015 13:56
Solution Interview

😡 I don't want this solution

😦 I don't need this solution

😐 I don't care about this solution

😄 This would be nice to have

😍 I must have this solution

@jasonsanjose
jasonsanjose / gist:6e5d86dc6609f97d3d3b
Last active August 29, 2015 14:03
requirejs-config.json

Advanced RequireJS Configuration

Background

Some extensions may require additional control over how RequireJS loads modules. Typical usage of RequireJS allows developers to configure these options via a configuration object.

Brackets' ExtensionLoader creates a unique require context for each extension to give each one it's own module namespace/sandbox. Since this can only be done with the global require, the extension loader has to do this prior to loading the extension's main.js.

Why?

@jasonsanjose
jasonsanjose / gist:3423dceec63b10e0c410
Created July 28, 2014 20:49
cookie shim with localStorage
var cookieVal = document.cookie,
testVal = "mixpanel",
localStorageKey = "mixpanel-cookie",
canWriteCookie = false;
// Test cookie
document.cookie = testVal;
canWriteCookies = document.cookie === testVal;
// Restore cookie
@jasonsanjose
jasonsanjose / gist:567b16762f6ae927fa81
Created August 21, 2014 15:55
Execute Brackets code hints
var Commands = brackets.getModule("command/Commands"),
CommandManager = brackets.getModule("command/CommandManager");
CommandManager.execute(Commands.SHOW_CODE_HINTS);