Skip to content

Instantly share code, notes, and snippets.

View kd0g's full-sized avatar

taewoong kdog kim kd0g

View GitHub Profile
@kd0g
kd0g / slack_vcards.py
Created June 29, 2022 09:17
List up Slack Users into Vcard Files
import pickle
import os
from slack_sdk import WebClient
import vobject
import requests
import base64
TMP_PATH = '/tmp/people.pkl'
def get_users_list(client):
@kd0g
kd0g / phone_replace.py
Last active July 5, 2022 08:50
iOS padOS 에서 전화번호 바꾸기 스크립트(pythonista필요)
import contacts
ppls = contacts.get_all_people()
changed = False
for p in ppls:
for phone in p.phone:
y, pnum = phone
if pnum.startswith('010'):
@kd0g
kd0g / gist:4de90b89ad7167a3a51da6a04235cae8
Created March 3, 2018 12:28 — forked from CristinaSolana/gist:1885435
Keeping a fork up to date

1. Clone your fork:

git clone git@github.com:YOUR-USERNAME/YOUR-FORKED-REPO.git

2. Add remote from original repository in your forked repository:

cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream
@kd0g
kd0g / phone_replace.scpt
Created March 3, 2018 12:10
MAC에서 전화번호 바꾸기 스크립트
tell application "Contacts"
-- repeat with aPerson in people of group "Test Group"
repeat with aPerson in people
set thePhones to phones of aPerson
if thePhones is not {} then
set errorList to {}
repeat with aPhoneNumber in thePhones
set theNumber to value of aPhoneNumber
try
set value of aPhoneNumber to my getNewNumber(theNumber)
# coding: utf8
'''
사실 문제 자체가 기억 안나서 구글신에 물어볼 뻔.
n == 2일 때, 어떻게 움직이면 좋을지 move()를 여러번 적어놓고 해결한 다음,
move(1, 3)
move(1, 2)
move(2, 3)
pp()를 만들고,