This file contains hidden or 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
| test-microphone() { | |
| arecord -vvv -f dat /dev/null | |
| } |
This file contains hidden or 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
| from vispy.visuals.graphs.util import _straight_line_vertices, issparse | |
| import networkx as nx, numpy as np | |
| class NetworkxCoordinates: | |
| def __init__(self, graph, layout = None, *args, **kwargs): | |
| self.graph = graph | |
| self.positions = np.zeros((len(graph), 2), dtype = np.float32) | |
| # default random positions | |
| if type(layout) is type(None): | |
| self.positions = np.random.rand(*self.positions.shape) | |
This file contains hidden or 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
| from subprocess import run | |
| from multiprocessing import cpu_count | |
| import os, click | |
| @click.command() | |
| @click.option('--source', default = "~/Phd/ereader") | |
| @click.option('--target', default = "~/Calibre Library") | |
| @click.option('--args', default = f"-as -w -ocr -nt {cpu_count()} -ocr -x -ui-") | |
| def run_reader(source, target, args): | |
| eReaderConverter(source, target, args).convert() |
This file contains hidden or 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 <pybind11/stl.h> | |
| #include <pybind11/pybind11.h> | |
| #include <pybind11/operators.h> | |
| namespace py = pybind11; | |
| using namespace pybind11::literals; | |
| using namespace std; | |
| template<typename T> | |
| class Property{ |
This file contains hidden or 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
| SPC s c remove highlight | |
| **** Files manipulations key bindings | |
| Files manipulation commands (start with ~f~): | |
| | Key Binding | Description | | |
| |-------------+----------------------------------------------------------------| | |
| | ~SPC f c~ | copy current file to a different location | | |
| | ~SPC f C d~ | convert file from unix to dos encoding | | |
| | ~SPC f C u~ | convert file from dos to unix encoding | |
This file contains hidden or 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
| git clone --bare https://github.com/cvanelteren/dots.git $HOME/.cfg | |
| function config { | |
| /usr/bin/git --git-dir=$HOME/.cfg/ --work-tree=$HOME $@ | |
| } | |
| mkdir -p .config-backup | |
| config checkout | |
| if [ $? = 0 ]; then | |
| echo "Checked out config."; | |
| else | |
| echo "Backing up pre-existing dot files."; |
NewerOlder