Skip to content

Instantly share code, notes, and snippets.

View gornostal's full-sized avatar

Oleksandr Gornostal gornostal

  • Kyiv, UA
View GitHub Profile
@gornostal
gornostal / README.md
Last active June 7, 2019 16:20
Install Hackintosh OS X Yosemite on Sony Vaio VPC-F11M1R/H

Successfully installed OS X Yosemite on my Sony VAIO F11M1R/H.

Problems:

  • I had to buy USB sound card for $10 (Viewcon VE533 works for me), because I couldn't find audio drivers.
  • OS X won't connect to password protected Wi-Fi networks, so I had to remove a password.

So here's the steps that I followed:

  1. Make a bootable flash drive using UniBeast tool
import React, { Component } from 'react'
import Helmet from 'react-helmet'
import QrCode from 'qrcode.react'
import { uploadImage, addJson, getJson, getIpfsHashFromBytes32, getBytes32FromIpfsHash } from '../utils/ipfs'
import './ipfs.css'
export default class Ipfs extends Component {
constructor(props) {
super(props)
@gornostal
gornostal / cors.sh
Last active May 14, 2018 09:33
IPFS Node
ipfs config --json API.HTTPHeaders.Access-Control-Allow-Origin '["*"]'
ipfs config --json API.HTTPHeaders.Access-Control-Allow-Methods '["PUT", "GET", "POST"]'
@gornostal
gornostal / rinkeby.sh
Created April 23, 2018 08:25
Run Rinkeby Node
#!/bin/bash
docker run \
--rm \
-d \
--name geth \
-v $(pwd)/.ethereum:/root/.ethereum \
-p 8545:8545 \
ethereum/client-go \
--rinkeby \
@gornostal
gornostal / format.sh
Last active January 20, 2018 16:58
Format USB drive from command line
lsblk
umount /dev/sdc
sudo fdisk /dev/sdc
d,d,d,d,...
n
w
sudo mkfs.vfat /dev/sdc1
sudo dd if=/path/to/ubuntu.iso of=/dev/sdb bs=1M
#!/bin/bash -eux
# This is a very simple example on how to bundle a Python application as an AppImage
# using virtualenv and AppImageKit using Ubuntu
# NOTE: Please test the resulting AppImage on your target systems and copy in any additional
# libraries and/or dependencies that might be missing on your target system(s).
########################################################################
# Get virtualenv on the target system
########################################################################
@gornostal
gornostal / readme.md
Created December 28, 2016 11:08
Ubuntu/Linux. Create SWAP file
  • sudo -i
  • cd /var
  • dd if=/dev/zero of=swap.file bs=1M count=2048
  • mkswap swap.file
  • chmod 600 swap.file
  • swapon swap.file
  • // copy UUID
  • vi /etc/fstab ==> UUID=f1ed55b6-357b-4427-86c8-d57f034cf29e none swap defaults 0 0
  • mount -a
  • echo $? // should be 0 if everything is OK
@gornostal
gornostal / Sound.md
Created February 5, 2016 21:28
HP Probook 430 G3 Ubuntu drivers
@gornostal
gornostal / audible-mongolab.js
Created September 15, 2013 12:53
Tampermonkey script for audible collections in mongolab
// ==UserScript==
// @name Audible-Mongolab
// @namespace http://use.i.E.your.homepage/
// @version 0.1
// @description https://gist.github.com/gornostal/6570516
// @match https://mongolab.com/databases/audible/collections/*
// @copyright 2012+, You
// ==/UserScript==
@gornostal
gornostal / audible.js
Last active December 23, 2015 02:59
Scrape audible search results
/**
* To run use http://nrabinowitz.github.com/pjscrape/
* 1. $ phantomjs pjscrape.js audible.js
* 2. Register on mongolab.com
* 3. $ mongoimport -h ds0466148.mongolab.com:45598 -d <dbname> -c <collection> -u <user> -p <password> --file audible.json --jsonArray
* 4. Install greasemonkey (Firefox) or tempermonkey (Chrome)
* 5. Add this userscript https://gist.github.com/gornostal/6570526
* 6. Open https://mongolab.com/databases/audible/collections/fiction_books or whatever you have
*/