Skip to content

Instantly share code, notes, and snippets.

View daxeh's full-sized avatar

Adrian Teh daxeh

  • Sydney, Australia
  • 21:30 (UTC +10:00)
View GitHub Profile
@daxeh
daxeh / DockerfileForSvelteKit.md
Created July 10, 2023 02:52 — forked from aradalvand/DockerfileForSvelteKit.md
Dockerfile and .dockerignore for SvelteKit:

This Dockerfile is intended for SvelteKit applications that use adapter-node. So, the Dockerfile below assumes that you have installed and configured adapter-node.

Dockerfile:

FROM node:18-alpine AS builder
WORKDIR /app
COPY package*.json .
RUN npm ci
COPY . .
RUN npm run build
@daxeh
daxeh / .gitignore
Created June 23, 2021 12:49 — forked from octocat/.gitignore
Some common .gitignore configurations
# Compiled source #
###################
*.com
*.class
*.dll
*.exe
*.o
*.so
# Packages #
@daxeh
daxeh / index.html
Created October 22, 2018 09:13
JS Bin mirus-problem1 // source https://jsbin.com/wuxajij
<!DOCTYPE html>
<html>
<head>
<meta name="description" content="mirus-problem1">
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
@daxeh
daxeh / index.html
Created October 22, 2018 09:13
JS Bin mirus-problem1 // source https://jsbin.com/wuxajij
<!DOCTYPE html>
<html>
<head>
<meta name="description" content="mirus-problem1">
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
@daxeh
daxeh / index.html
Created October 22, 2018 09:13
JS Bin mirus-problem2 // source https://jsbin.com/sixitam
<!DOCTYPE html>
<html>
<head>
<meta name="description" content="mirus-problem2">
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
@daxeh
daxeh / index.html
Created June 25, 2018 05:17
Submarine with CSS
<div class="sea">
<div class="circle-wrapper">
<div class="bubble"></div>
<div class="submarine-wrapper">
<div class="submarine-body">
<div class="window"></div>
<div class="engine"></div>
<div class="light"></div>
</div>
<div class="helix"></div>
@daxeh
daxeh / AdhocModel.js
Last active June 20, 2018 02:17
An infinite data feed stream React container that fetches json data into a stateless presenter component
/**
* Adhoc non-persistent model for demo/development purposes (single session).
* @type {{}}
*/
const m = {};
const AdhocModel = {
add: (k, v) => {
m[ k ] = v;
//console.log(m);

Multiple MySQL Versions with Homebrew

For homebrew version 0.9.5.

brew -v # => Homebrew 0.9.5

Install the current version of mysql.

# Install current mysql version

brew install mysql

@daxeh
daxeh / .bash_profile
Created December 21, 2017 01:15
OSX .bash_profile
#!/usr/bin/env bash
## bash_profile
## .:hex ... ....- -..- --- .-. .. xǝɥ:.
export PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
export ARCHFLAGS='-arch x86_64'
export CLICOLOR=1
export LSCOLORS=Exfxcxdxbxegedabagacad
export GREP_OPTIONS='--color=auto'
@daxeh
daxeh / macosx.config
Created December 1, 2017 16:29
Environment essential configurations
## Disable Desktop
defaults write com.apple.finder CreateDesktop -bool FALSE;killall Finder
## Set default screenshot location
defaults write com.apple.screencapture location ~/Pictures/screenshots
## Add CMD+q to Finder
defaults write com.apple.finder QuitMenuItem -bool yes;killall Finder
## Disable ARD Agent