- Ditch the status page
- Expose the entire thing as a library
- 📝 the world
- Update the main README
- Finish the install PR
- Fix up surf-clean and add remote clean
- Remove the ref server concept and rename surf-client
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
ObservableKeyboard.InputProfileChanged | |
.Subscribe(_ => Console.WriteLine("Hey it changed!")); |
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
import * as fs from 'fs'; | |
import * as path from 'path'; | |
import * as glob from 'glob'; | |
import * as cheerio from 'cheerio'; | |
const files = glob.sync(path.join(__dirname, '**/*.html')); | |
const filesAndContent = files.reduce((acc, x) => { | |
let $ = cheerio.load(fs.readFileSync(x, 'utf8')); |
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
export interface SortedArrayOpts { | |
filter?: Function; | |
compare?: Function | string; | |
unique?: boolean; | |
resume?: boolean; | |
} | |
export class SortedArray<T> extends Array<T> { | |
private readonly _filter: Function; | |
private readonly _compare: Function; |
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
// | |
// WRONG | |
/// | |
class InMemorySparseMap<K, V> implements SparseMap<K, V> { | |
private latest: Map<K, Updatable<V>>; | |
private factory: ((key: K) => Observable<V>) | undefined; | |
subscribe(key: K): Updatable<V> { | |
let ret = this.latest.get(key); |
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
runtime = electron | |
target = 1.4.12 // REPLACE ME WITH VERSION | |
target_arch = x64 // REPLACE ME WITH WHATEVER process.arch IS | |
disturl = https://atom.io/download/atom-shell | |
tag-version-prefix = "" | |
build_from_source = true |
This file has been truncated, but you can view the full file.
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
use std::cell::RefCell; | |
use std::collections::LinkedList; | |
use std::sync::atomic::*; | |
pub trait Subscription { | |
fn unsubscribe(&mut self); | |
fn closed(&self) -> bool; | |
} | |
/* |
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
// Include this at the very top of both your main and window processes, so that | |
// it loads as soon as possible. | |
// | |
// Why does this work? The node.js module system calls fs.realpathSync a _lot_ | |
// to load stuff, which in turn, has to call fs.lstatSync a _lot_. While you | |
// generally can't cache stat() results because they change behind your back | |
// (i.e. another program opens a file, then you stat it, the stats change), | |
// caching it for a very short period of time is :ok: :gem:. These effects are | |
// especially apparent on Windows, where stat() is far more expensive - stat() | |
// calls often take more time in the perf graph than actually evaluating the |
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
is64BitOperatingSystem: () => { | |
if (process.arch === 'x64') return true; | |
let sysRoot = 'C:\\Windows'; | |
if (fs.statSyncNoException(process.env.SYSTEMROOT || 'C:\\__nothere__')) { | |
sysRoot = process.env.SYSTEMROOT; | |
} | |
// If %SystemRoot%\SysNative exists, we are in a WOW64 FS Redirected application. | |
return !!fs.statSyncNoException(path.join(sysRoot, 'sysnative')); |