Skip to content

Instantly share code, notes, and snippets.

@pfitzseb
pfitzseb / june-dark.css
Created September 5, 2014 17:57
June-dark
#multi.theme-june-dark .content { background: #172734; }
#multi.theme-june-dark .list .active, #multi.theme-june-dark .list li:hover { background:#172734; color:#eee; }
#multi.theme-june-dark .list .dirty { color:#f50; }
.cm-s-june-dark { background: #172734; color: #eee }
.cm-s-june-dark span.cm-keyword {color: #40B0E0; font-weight:bold;} /* if, while... */
.cm-s-june-dark span.cm-atom {color: #5B90D4;}
.cm-s-june-dark span.cm-number {color: #009999;}
.cm-s-june-dark span.cm-def {color: #FC9906; font-weight: bold;} /* function definition */
.cm-s-june-dark span.cm-variable {color: #eee;}
@pfitzseb
pfitzseb / gist:67da9500a7c0a27539fe
Last active August 29, 2015 14:07
JunoLab tutorial
  • explain default keybinds and link a tutorial for behaviour-files
  • add a note about changing the current folder to the one the current file is opened in, e.g. cd(dirname(@__FILE__))
# Welcome to Juno!
# If you're new to Julia, you can find a tutorial here:
# http://link to a nice tutorial.com
# Generally, if there's something you'd like to do but don't know how, try
# searching in the command bar (Ctrl + Space) - almost all possible commands
# can be found there.
# To evaluate a line of code, press C + Enter¹. The result will be displayed

One session:

julia> function foo(z)
         c = 100
         max = 80
         for n = 1:max
           abs(z) ≥ 2 && return n-1
           z = z^2 + c
         end
         return max
1 required packages:
- Atom 0.4.2+ master
43 additional packages:
- ASTInterpreter 0.0.2+ master
- AbstractTrees 0.0.2
- BinDeps 0.3.21+ master
- Blink 0.3.4+ master
- CodeTools 0.3.0+ master
- Codecs 0.1.5
- ColorTypes 0.2.2
@pfitzseb
pfitzseb / gist:1541c0eeaca6b5c42765024d3fccf83f
Created September 25, 2016 20:25
METADATA.jl travis log
Using worker: worker-linux-docker-8ee3aa76.prod.travis-ci.org:travis-linux-2
system_info
Build system information
Build language: generic
Build group: stable
julia> versioninfo()
Julia Version 0.5.0
Commit 3c9d753 (2016-09-19 18:14 UTC)
Platform Info:
System: NT (x86_64-w64-mingw32)
CPU: Intel(R) Core(TM) i5-4570 CPU @ 3.20GHz
WORD_SIZE: 64
BLAS: libopenblas (USE64BITINT DYNAMIC_ARCH NO_AFFINITY Haswell)
LAPACK: libopenblas64_
LIBM: libopenlibm
@pfitzseb
pfitzseb / module.jl
Created November 25, 2016 13:19
codemodule
using Tokenize
SCOPE_STARTERS = [Tokenize.Tokens.BEGIN,
Tokenize.Tokens.WHILE,
Tokenize.Tokens.IF,
Tokenize.Tokens.FOR,
Tokenize.Tokens.TRY,
Tokenize.Tokens.FUNCTION,
Tokenize.Tokens.MACRO,
Tokenize.Tokens.LET,
~/Documents/julia  master  j6  ✓  19:55:43
_
_ _ _(_)_ | A fresh approach to technical computing
(_) | (_) (_) | Documentation: https://docs.julialang.org
_ _ _| |_ __ _ | Type "?help" for help.
| | | | | | |/ _` | |
| | |_| | | | (_| | | Version 0.6.1-pre.unknown (2017-10-07 01:18 UTC)
_/ |\__'_|_|_|\__'_| | Commit 389b23c* (3 days old release-0.6)
|__/ | x86_64-redhat-linux
@pfitzseb
pfitzseb / didWriteToREPL.jl
Created January 25, 2018 15:52
didWriteToREPL.jl
function didWriteToREPL(f)
origout = STDOUT
rout, wout = redirect_stdout()
didWrite = false
t = @async begin
r = ""
didWriteLinebreak = false
while isopen(rout)