Skip to content

Instantly share code, notes, and snippets.

View bmpvieira's full-sized avatar

Bruno Vieira bmpvieira

  • Lifebit
View GitHub Profile
(defun vulpea-project-p ()
"Return non-nil if current buffer has any todo entry.
TODO entries marked as done are ignored, meaning the this
function returns nil if current buffer contains only completed
tasks."
(seq-find ; (3)
(lambda (type)
(eq type 'todo))
(org-element-map ; (2)
@limepanda
limepanda / kvm-migration.txt
Last active January 26, 2024 23:26
migrate qcow2 image to zfs volume
qemu-img convert -O raw <infile.(vdi|vmdk|$whatever)> /dev/zvol/rpool/data/<vmid>-disk0
@mafintosh
mafintosh / npm-classic-config.sh
Last active June 21, 2018 17:40
Resets the npm defaults to how they used to be
npm config set loglevel http
npm config set progress false
npm config set package-lock false
npm config set save false
mkdir -p ~/.config/configstore/
printf '{"optOut": true,"lastUpdateCheck": 0}' > ~/.config/configstore/update-notifier-npm.json
@blahah
blahah / pubmed_retractions.sh
Last active May 9, 2017 14:39
easily find retracted papers in PubMed, using only bionode-ncbi and jq
# you'll need:
# - bionode-ncbi (https://github.com/bionode/bionode-ncbi)
# - jq (https://github.com/stedolan/jq)
# count the number of retracted papers
bionode-ncbi search pubmed "\"Retracted Publication\"" \
| jq -c 'select(.pubtype[] | inside("Retracted Publication"))'
| wc -l
# get DOIs for all the retracted papers
@zimbatm
zimbatm / README.md
Created March 29, 2017 09:32
Nixpkgs pinning example

Nixpkgs pinning example

This is an example of how to pin the version of nixpkgs in a package repo. The goal is to improve reproducibility, make sure all the developers use the same version of nixpkgs and also allow to share binary caches.

Usage

Put all these files in a nixpkgs folder and then in other derivations, instead of import <nixpkgs> {} use import ./path/to/nixpkgs {}

Keeping nixpkgs up to date

@rauchg
rauchg / README.md
Last active January 6, 2024 07:19
require-from-twitter
// install node 4.2.2
function foo () {
console.log('----------------------------')
foo()
}
foo()
@rgbkrk
rgbkrk / jupyter-in-the-javascript-universe.md
Last active December 7, 2015 13:08
Jupyter in the JavaScript Universe

The Jupyter and IPython projects have been around more than 10 years and a lot has changed over the years in terms of frontend development: V8, Node, npm, transpilers, JS Compilers, competing module loading systems, auto-updating browsers, new frameworks, and many other bits. They've all come and made front end development much better. At the same time, they've bred complexity in choice and decisions. Some of the biggest warts have been the document API for the DOM, how we work on it, the tendency to get addicted to the ease of jQuery, and the resulting jQuery soup that gets created. Large projects have to make a choice on how they're going to package and ship components of their overall application.

There was a time at which I was comfortable in CoffeeScript. Now that I've read JavaScript the Good Parts, Node.js the Right Way, read and written [more](https://github.com/nteract/jupyter-sideca

advert said: "Titus will talk about the pros and cons of graduate school, how to choose if graduate school is a good fit for you, and tips for applying to graduate school"

see also:

https://www.netjeff.com/humor/item.cgi?file=GradSchoolOrHell

--

Grad school is very dependent on advisor, dept; talk to current grad students beforehand!

@max-mapper
max-mapper / test.js
Last active August 29, 2015 14:24
tape + http local server test scaffolding
// the two testing modules I like
var test = require('tape')
var spawn = require('tape-spawn')
var execspawn = require('npm-execspawn') // can spawn from require() scope, check it out!
// put this in outer scope so we can kill the local server at the end
var server
test('start test server', function (t) {