https://forum.level1techs.com/t/vega-10-and-12-reset-application/145666
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
| //StackOverflow solution by me here: https://stackoverflow.com/a/52564925/8170714 | |
| public static void setEditTextCursorColor(EditText editText, int color) { | |
| try { | |
| // Get the cursor resource id | |
| Field field = TextView.class.getDeclaredField("mCursorDrawableRes"); | |
| field.setAccessible(true); | |
| int drawableResId = field.getInt(editText); | |
| // Get the editor |
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
| #!/bin/bash | |
| function install_dependencies() { | |
| echo "Installing dependencies..." | |
| sudo apt -qq update | |
| sudo apt -qq install -y curl git wget | |
| # sudo apt -qq install -y bison flex kernel-package libelf-dev libssl-dev | |
| sudo apt -qq install -y bison flex libelf-dev libssl-dev | |
| } |
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
| server { | |
| listen 80; | |
| server_name your.domain.com; | |
| location = /analytics.js { | |
| # you have to compile nginx with http://nginx.org/en/docs/http/ngx_http_sub_module.html (this is not default) | |
| # and http://nginx.org/en/docs/http/ngx_http_proxy_module.html (it's a default module) | |
| proxy_set_header Accept-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
| #!/usr/bin/env python3 | |
| # | |
| # Dumb script to dump (some) of bcache status | |
| # Copyright 2013 Darrick J. Wong. All rights reserved. | |
| # | |
| # This file is part of Bcache. Bcache is free software: you can | |
| # redistribute it and/or modify it under the terms of the GNU General Public | |
| # License as published by the Free Software Foundation, version 2. | |
| # | |
| # This program is distributed in the hope that it will be useful, but WITHOUT |
The official installation guide (https://wiki.archlinux.org/index.php/Installation_Guide) contains a more verbose description.
- Image from https://www.archlinux.org/
DRI_PRIME=1 glxinfo | grep OpenGL
echo "1002 6719" > /sys/bus/pci/drivers/vfio-pci/new_id echo "0000:01:00.0" > /sys/bus/pci/devices/0000:01:00.0/driver/unbind echo "0000:01:00.0" > /sys/bus/pci/drivers/vfio-pci/bind echo "1002 6719" > /sys/bus/pci/drivers/vfio-pci/remove_id echo "1002 aa80" > /sys/bus/pci/drivers/vfio-pci/new_id echo "0000:01:00.1" > /sys/bus/pci/devices/0000:01:00.1/driver/unbind
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
| #!/usr/bin/env bash | |
| #Build and install neovim for Debian | |
| #See: https://neovim.io/ | |
| #See: https://github.com/neovim/neovim/wiki/Building-Neovim#quick-start | |
| #See: https://gist.github.com/darcyparker/153124662b05c679c417 | |
| #Save current dir | |
| pushd . >/dev/null || exit |
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
| # Thanks to this post: | |
| # http://blog.ikato.com/post/15675823000/how-to-install-consolas-font-on-mac-os-x | |
| $ brew install cabextract | |
| $ cd ~/Downloads | |
| $ mkdir consolas | |
| $ cd consolas | |
| $ curl -O http://download.microsoft.com/download/f/5/a/f5a3df76-d856-4a61-a6bd-722f52a5be26/PowerPointViewer.exe | |
| $ cabextract PowerPointViewer.exe | |
| $ cabextract ppviewer.cab |