Skip to content

Instantly share code, notes, and snippets.

View CreatiCoding's full-sized avatar
🎯
I may be slow to respond.

정석호 CreatiCoding

🎯
I may be slow to respond.
View GitHub Profile
@CreatiCoding
CreatiCoding / getCalendarEvents.ts
Created August 31, 2024 07:26
Google Calendar List API w/Node.js SDK
import * as calendar from "@googleapis/calendar";
import { format, subDays, addDays, toDate } from "date-fns";
const auth = new calendar.auth.GoogleAuth({
credentials: {
client_email: process.env.GOOGLE_CLIENT_EMAIL,
private_key: process.env.GOOGLE_PRIVATE_KEY
},
scopes: ["https://www.googleapis.com/auth/calendar.readonly"],
});
@CreatiCoding
CreatiCoding / is-js-in.sh
Created March 13, 2023 14:28
is-js-in.sh
if [[ $(node -p "true") == "true" ]]; then
echo "it is true!"
fi
@CreatiCoding
CreatiCoding / skip.sh
Created October 17, 2022 11:41
package'scripts: command 없으면 실행하지 않기
{ command -v || exit 0; } && command something
@CreatiCoding
CreatiCoding / remove-workflow-job.js
Created October 1, 2022 16:03
github action 마지막 workflow 자동으로 지우기
setTimeout(() => [...document.querySelectorAll('.timeline-comment-action.btn-link')].pop().click(), 0);
setTimeout(() => [...document.querySelectorAll('.details-overlay.details-overlay-dark.details-reset > summary')].pop().click(), 500);
setTimeout(() => document.querySelector('.btn-danger.btn.btn-block').click(), 1000);
@CreatiCoding
CreatiCoding / github-action.ssh.yaml
Created September 30, 2022 08:33
github-action for ssh commands
name: remote ssh command
on: [push]
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Deploy
run: |
https://github.com/milooy/remote-or-flexible-work-company-in-korea
@CreatiCoding
CreatiCoding / example.sh
Created November 1, 2021 11:44
echo "N files changed, M insertions(+)"
git diff HEAD --shortstat
@CreatiCoding
CreatiCoding / readme.md
Created October 27, 2021 08:14
when your account dosen't have permission of /usr/local/bin, do this.

Error: The following directories are not writable by your user:

/usr/local/bin

You should change the ownership of these directories to your user.

  sudo chown -R $(whoami) /usr/local/bin
@CreatiCoding
CreatiCoding / rancher.desktop.error.sh
Created October 24, 2021 11:02
rancher desktop 설치시 오류나면
# rancher desktop 설치시 오류나면
sudo ln -s "/Applications/Rancher Desktop.app/Contents/Resources/resources/darwin/bin/nerdctl" nerdctl
git update-index --assume-unchanged file