Skip to content

Instantly share code, notes, and snippets.

View keybase.md

Keybase proof

I hereby claim:

  • I am chriswdixon on github.
  • I am chriswdixon (https://keybase.io/chriswdixon) on keybase.
  • I have a public key ASD4-2qAyN3ic56bLy_dFd_mFgTkkOYo8Wtuzxi9oJAAvQo

To claim this, I am signing this object:

View Potential Maintainers
Maintainers:
eadwu: cascadia-code, cascadia-code, cascadia-code, cascadia-code
View Changed Paths
aarch64-linux cascadia-code
x86_64-linux cascadia-code
i686-linux cascadia-code
x86_64-darwin cascadia-code
@gitaficionado
gitaficionado / PrintTableWithCasting_02_18.java
Created Sep 20, 2019
(Print a table) Write a program that displays the following table. Cast floating-point numbers into integers. See page 68 for more information.
View PrintTableWithCasting_02_18.java
public class PrintTableWithCasting_02_18 {
// Main method
public static void main(String[] args) {
System.out.println("a b _____(a, b)");
System.out.println("1 2 " + (___)____.___(1, 2));
System.out.println("2 3 " + (___)____.___(2, 3));
System.out.println("3 4 " + (__)___.___(3, 4));
System.out.println("4 5 " + (___)___.__(4, 5));
System.out.println("5 6 " + (___)____.___(5, 6));
}
View .gitconfig
[user]
email = laitinson@gmail.com
name = Tinson Lai
signingKey = %Key%
[commit]
gpgsign = true
[tag]
forceSignAnnotated = true
gpgSign = true
[core]
@netnr
netnr / proxy_store.conf
Created Sep 20, 2019
nginx反向代理永久缓存文件,整站下载利器
View proxy_store.conf
server {
listen 66;
location / {
if (!-e $request_filename) {
proxy_pass https://www.netnr.com;
}
root D:\\Software\\nginx\\conf\\tmp;
proxy_store on;
proxy_store_access user:rw group:rw all:r;
View install.sh
#!/bin/bash
export DEBIAN_FRONTEND='noninteractive'
pve5to6
systemctl stop pve-ha-lrm
systemctl stop pve-ha-crm
echo "deb http://download.proxmox.com/debian/corosync-3/ stretch main" > /etc/apt/sources.list.d/corosync3.list
apt update
DEBIAN_FRONTEND='noninteractive' apt-get -y -o Dpkg::Options::='--force-confdef' -o Dpkg::Options::='--force-confold' dist-upgrade
sed -i 's/stretch/buster/g' /etc/apt/sources.list
apt update
View keybase.md

Keybase proof

I hereby claim:

  • I am xrobau on github.
  • I am xrobau (https://keybase.io/xrobau) on keybase.
  • I have a public key ASBtGiCkZGkKTW6SG9qn35weQYgyAQqbMjSpaP0vsXV8oQo

To claim this, I am signing this object:

View self-assessment-1.js
function convertTo(units, num) {
//Do not worry about formatting your output to round to the nearest 2nd decimal number.
if (units === 'cm') {
return num * 2.54;
} else if (unites === 'in') {
return num / 2.54;
}
}
//=================================================
@benald
benald / Cross-browser viewport height and width JS variables
Created Sep 20, 2019
An accurate cross browser / device viewport measurement
View Cross-browser viewport height and width JS variables
// Set cross-browser viewport height and width variable
viewHeight = Math.max(document.documentElement.clientHeight, window.innerHeight || 0);
viewWidth = Math.max(document.documentElement.clientWidth, window.innerWidth || 0);
You can’t perform that action at this time.