Windows Subsystem 2 for Linux, Hyper, ZSH + Oh My Zsh + Powerlevel9k + plugins, FNM + VSCode (+ext) and Nerd Font
To setup native Linux, see this gist
// Date : 28/05/2021 | |
// Last Updated : 04/05/2022 | |
// Author : Ghassane SEBAÏ | |
// Contact : [email protected] | |
// Source : https://en.wikipedia.org/wiki/List_of_iOS_and_iPadOS_devices | |
// Format : | |
// "Model Name : [Hardware Strings]" | |
// -> Using '/' as a separator between hardware strings. |
#!/usr/bin/env python3 | |
# !! NOTE - this script is no longer maintained... please see the repo for further | |
# updates: https://github.com/jheddings/notes2notion | |
# this script attempts to migrate from Apple Notes to Notion while retaining as | |
# much information and formatting as possible. there are limitations to the | |
# export data from Notes, so we try to preserve the intent of the original note. | |
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, |
import React from "react"; | |
import axios from "axios"; | |
const sitemapXml = data => { | |
let latestPost = 0; | |
let projectsXML = ""; | |
data.map(post => { | |
const postDate = Date.parse(post.modified); | |
if (!latestPost || postDate > latestPost) { |
Windows Subsystem 2 for Linux, Hyper, ZSH + Oh My Zsh + Powerlevel9k + plugins, FNM + VSCode (+ext) and Nerd Font
To setup native Linux, see this gist
$positions: ( | |
t: ('top'), | |
r: ('right'), | |
b: ('bottom'), | |
l: ('left'), | |
x: ('left', 'right'), | |
y: ('top', 'bottom') | |
); | |
@mixin sizeValue($prop, $i) { |
'use strict'; | |
const crypto = require('crypto'); | |
const ENC_KEY = "bf3c199c2470cb477d907b1e0917c17b"; // set random encryption key | |
const IV = "5183666c72eec9e4"; // set random initialisation vector | |
// ENC_KEY and IV can be generated as crypto.randomBytes(32).toString('hex'); | |
const phrase = "who let the dogs out"; | |
var encrypt = ((val) => { |
// Node v6.9.0 | |
// | |
// TEST FILE (cut down for simplicity) | |
// To ensure Golang encrypted string can be decrypted in NodeJS. | |
// | |
let crypto; | |
try { | |
crypto = require('crypto'); |
const webpack = require('webpack'); | |
require('dotenv').config({ | |
path: process.env.NODE_ENV === 'production' ? '.env.production' : '.env' | |
}); | |
module.exports = { | |
webpack: config => { | |
const env = Object.keys(process.env).reduce((acc, curr) => { | |
acc[`process.env.${curr}`] = JSON.stringify(process.env[curr]); |
# Automatic nginx virtual subdomains with sub-folders or sub-directories | |
# | |
# Since the original source where I found this code is now offline, I have decided to mirror it here. | |
# All credit goes to: http://web.archive.org/web/20150307193208/http://www.messaliberty.com/2010/10/automatic-nginx-virtual-subdomains-with-sub-folders-or-sub-directories | |
# | |
# Description: In my web root directory I wanted create a folder called photos, and another called | |
# music using a sftp program. Without manually going back to the config file or to the shell I like to | |
# be able to access them at photos.nginxdomain.com and music.nginxdomain.com. That is what this config does. | |
# Redirect visitors from http://nginxdomain.com/ to http://www.nginxdomain.com/ |