Skip to content

Instantly share code, notes, and snippets.

View qileq's full-sized avatar
💭
🙃

qileq qileq

💭
🙃
View GitHub Profile
@qileq
qileq / generate_date.MD
Last active July 29, 2022 06:10
Shell common methods quick query
  • Generate date from start day to end day
    Smaple:
#!/bin/bash

cur="2022-03-01"
end="2022-03-31"
while [[ "$cur" < "$end" ]] 
do
 cur=`date -d "${cur} 1day" +"%Y-%m-%d"`
@qileq
qileq / update_node_step.md
Last active March 31, 2022 07:28
upgrade node and npm

npm

  1. cuurent npm version: npm -v
  2. install lastest version: npm install -g npm@latest
  3. check npm version: npm -v

node

  1. current node version: node -v
  2. clean cache: sudo npm cache clean -f
  3. install n: sudo npm install -g n
  4. install lastest stable node: sudo n stable or install some specify version: sudo n 16.14.2
@qileq
qileq / limit.maxfiles.plist
Last active January 31, 2023 02:08
How to Change Open Files Limit on macOS Monterey
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>limit.maxfiles</string>
<key>ProgramArguments</key>
<array>
<string>launchctl</string>
<string>limit</string>