Skip to content

Instantly share code, notes, and snippets.

View Syakhisk's full-sized avatar
💻
most likely on my laptop at the moment

Syakhisk Al-Azmi Syakhisk

💻
most likely on my laptop at the moment
View GitHub Profile

via (https://www.linux.com/learn/tutorials/442438-vim-tips-folding-fun)

  • zf#j creates a fold from the cursor down # lines.
  • zf/string creates a fold from the cursor to string .
  • zj moves the cursor to the next fold.
  • zk moves the cursor to the previous fold.
  • zo opens a fold at the cursor.
  • zO opens all folds at the cursor.
  • zm increases the foldlevel by one.
  • zM closes all open folds.
@Syakhisk
Syakhisk / asdf-ignore-no-tracked
Last active April 22, 2024 03:26
ignore asdf .tool-version without changing codebase
git update-index --assume-unchanged .tool-versions
@Syakhisk
Syakhisk / diagram.drawio
Created March 25, 2024 09:10
Draw.io Sketch Diagram Template
<mxfile host="Electron" modified="2024-03-25T09:09:58.081Z" agent="Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) draw.io/24.1.0 Chrome/120.0.6099.109 Electron/28.1.0 Safari/537.36" etag="0CWKCcv9lyJe-H_TPLCL" version="24.1.0" type="device">
<diagram name="Page-1" id="nulhfqnfG4wDmLJvLztY">
<mxGraphModel dx="1793" dy="1249" grid="1" gridSize="10" guides="1" tooltips="1" connect="1" arrows="1" fold="1" page="0" pageScale="1" pageWidth="850" pageHeight="1100" math="0" shadow="0">
<root>
<mxCell id="0" />
<mxCell id="1" parent="0" />
<mxCell id="JcVpyYaejHqaoDqhhDGS-1" value="" style="edgeStyle=orthogonalEdgeStyle;hachureGap=4;html=1;fontFamily=Architects Daughter;fontSource=https%3A%2F%2Ffonts.googleapis.com%2Fcss%3Ffamily%3DArchitects%2BDaughter;fontSize=16;strokeWidth=1;" edge="1" parent="1" source="JcVpyYaejHqaoDqhhDGS-3" target="JcVpyYaejHqaoDqhhDGS-6">
<mxGeometry relative="1" as="geometry" />
</mxCell>
<m
// ==UserScript==
// @name Workday Auto Login
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @match https://wd3.myworkday.com/wday/authgwy/gojek/login.*
// @icon https://www.google.com/s2/favicons?sz=64&domain=workday.com
// @grant none
// @run-at document-end
// ==UserScript==
// @name Google SSO Account Picker
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @match https://accounts.google.com/*
// @icon https://www.google.com/s2/favicons?sz=64&domain=accounts.google.com
// @grant none
// @run-at document-end
// ==UserScript==
// @name Google Account Auto Switcher
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @match https://calendar.google.com/calendar/u/0/*
// @match https://drive.google.com/drive/u/0/*
// @match https://mail.google.com/mail/u/0/*
/**
* Install the plugin "Local REST API" and enable it.
* https://github.com/coddingtonbear/obsidian-local-rest-api
*
* Explore the API:
* https://coddingtonbear.github.io/obsidian-local-rest-api/
*/
import axios from "axios";
import https from "https";
#!/bin/env bash
VPN_PATH="$HOME/VPNs/MYITS-OPENVPN"
VPN_CONFIG="$VPN_PATH/its-onefile-2.ovpn"
EXPIRED_FILE="$HOME/VPNs/expired.txt"
EXPIRED_DATE="$(cat "$EXPIRED_FILE" | grep "Expired:" | awk -F'Expired:' '{print $2}')"
if [ -n "$TMUX" ]; then
tmux rename-window "VPN"
@Syakhisk
Syakhisk / mock-axios.js
Created June 12, 2023 07:57 — forked from cowboy/mock-axios.js
axios mocking via interceptors
import axios from 'axios'
let mockingEnabled = false
const mocks = {}
export function addMock(url, data) {
mocks[url] = data
}