Skip to content

Instantly share code, notes, and snippets.

View minhqnd's full-sized avatar
👽
still alive

Quang Minh minhqnd

👽
still alive
View GitHub Profile
@minhqnd
minhqnd / export_fap_calendar.md
Last active January 17, 2026 19:01
Xuất lịch học từ FAP (FPT Academic Portal) sang file ICS để import vào Apple Calendar / Google Calendar.

FAP to Calendar

Xuất lịch học từ FAP (FPT Academic Portal) sang file ICS để import vào Apple Calendar / Google Calendar.

Tính năng

  • Xuất lịch học của tất cả các môn trong kỳ hiện tại
  • Support vị trí 5 cơ sở FPT: Hòa Lạc, Đà Nẵng, Cần Thơ, HCM, Quy Nhơn
  • Tự động thông báo thời gian di chuyển dựa vị trí trên
@minhqnd
minhqnd / fap.py
Last active February 12, 2025 18:01
Convert FAP FPT Calendar to ics
import json
import uuid
from datetime import datetime, timezone
def create_event(data):
"""Format each event for the iCalendar file with Apple-specific attributes."""
event_template = """BEGIN:VEVENT
TRANSP:OPAQUE
DTSTART;TZID=Asia/Ho_Chi_Minh:{start_time}
DTEND;TZID=Asia/Ho_Chi_Minh:{end_time}
@sontl
sontl / country-detect-cf-worker.js
Created December 27, 2024 07:49
Country detection using CF Worker
addEventListener('fetch', event => {
event.respondWith(handleRequest(event.request))
})
async function handleRequest(request) {
const headers = {
'Access-Control-Allow-Origin': '*',
'Content-Type': 'application/json'
}
@QuanTrieuPCYT
QuanTrieuPCYT / FPTU.md
Created April 15, 2024 13:04
FPTU Kỳ Truyện - Đại học FPT: khi sinh viên gian lận và hack vào server trường

Đại học FPT: khi sinh viên gian lận và hack vào server trường

Lấy từ nguồn: https://tinhte.vn/thread/dai-hoc-fpt-khi-sinh-vien-gian-lan-va-hack-vao-server-truong.1091706/


Trường Đại Học FPT (FU) số 8 Tôn Thất Thuyết - Cầu Giấy - Hà Nội (Toà nhà Detect - đối diện bến xe Mĩ Đình) Trong 3 năm nay, FU có thực hiện việc thi cử online bằng phần mềm chuyên dụng của trường, được nhà trường đặt hàng của Phan Trường Lâm (LamPT) có 2 phiên bản đều được code bằng C# .NET:
1- bản EOS Client dùng thi môn Business English (BE).
2- bản IT Client thi các môn Software Engineering: Java, C#, C/C+- Computer Network, Operating System (OS), Introduction to Database, ...

@0187773933
0187773933 / OneDriveRemoverOSX.sh
Last active August 17, 2025 18:18
Completely Uninstalls OneDrive from Mac OSX and all settings just change username
#!/bin/bash
sudo pkill -9 OneDrive
sudo rm -rf /Applications/OneDrive.app/
sudo rm /Library/LaunchAgents/com.microsoft.OneDriveStandaloneUpdater.plist
sudo rm /Library/LaunchDaemons/com.microsoft.OneDriveStandaloneUpdaterDaemon.plist
sudo rm /Library/LaunchDaemons/com.microsoft.OneDriveUpdaterDaemon.plist
sudo rm -rf /Library/Logs/Microsoft/OneDrive
sudo rm /private/var/db/receipts/com.microsoft.OneDrive-mac.bom
@josephg
josephg / 0dedict.py
Last active January 25, 2026 06:17
Apple dictionaries
# Thanks to commenters for providing the base of this much nicer implementation!
# Save and run with $ python 0dedict.py
# You may need to hunt down the dictionary files yourself and change the awful path string below.
# This works for me on MacOS 10.14 Mohave
from struct import unpack
from zlib import decompress
import re
filename = '/System/Library/Assets/com_apple_MobileAsset_DictionaryServices_dictionaryOSX/9f5862030e8f00af171924ebbc23ebfd6e91af78.asset/AssetData/Oxford Dictionary of English.dictionary/Contents/Resources/Body.data'
f = open(filename, 'rb')