Skip to content

Instantly share code, notes, and snippets.

View kwunyeung's full-sized avatar
💛
When we are all yellow...

Kwun Yeung kwunyeung

💛
When we are all yellow...
View GitHub Profile

Keybase proof

I hereby claim:

  • I am kwunyeung on github.
  • I am kwunyeung (https://keybase.io/kwunyeung) on keybase.
  • I have a public key ASBKle1_ImJusPpwHeOAlNI6BMlKmtb2b-UB_JAZJedtego

To claim this, I am signing this object:

@kwunyeung
kwunyeung / gaia_upgrade.sh
Last active January 13, 2023 06:29
script to upgrade the Cosmos gaia testnet
#!/bin/bash
# Upgrade Cosmos SDK and restart gaiad
POSITIONAL=()
while [[ $# -gt 0 ]]
do
key="$1"
case $key in
-t|--tag)
@kwunyeung
kwunyeung / gaia_install.sh
Last active January 13, 2023 06:28
bash script for installing go and gaia cosmoshub-1 on Ubuntu
#!/bin/bash
# Upgrade the system and install go
sudo apt update
sudo apt upgrade -y
sudo apt install gcc git make -y
sudo snap install --classic go
sudo mkdir -p /opt/go/bin
# Export environment variables
@kwunyeung
kwunyeung / gaiad.service
Last active January 12, 2023 14:03
systemd unit file of Cosmos gaia testnet
[Unit]
Description=Cosmos Gaia Node
After=network-online.target
[Service]
User=gaiad
ExecStart=/opt/go/bin/gaiad start --home=/opt/gaiad/
Restart=always
RestartSec=3
LimitNOFILE=4096
@kwunyeung
kwunyeung / SearchBar.jsx
Last active May 7, 2018 03:46
Search bar
toggleSearchInput = e => {
e.preventDefault();
this.setState({isShown = !this.state.isShown});
}
render(){
return
<div>
(this.state.isShown?
<SearchInput />:''}
<?php
/**
* Coordinates.php
* An utility for converting HK80 to WGS84 coordinates
*
* Copyright (C) 2010, 2013 Kelvin Wong
* Licensed under the MIT License (http://opensource.org/licenses/MIT)
*
* Note: For the glossaries and conventions for coordinates convertion, please refer to
* the website of Geodetic Survey of Hong Kong.