Skip to content

Instantly share code, notes, and snippets.

Avatar

Lin, Yong Xiang r888800009

View GitHub Profile
@niw
niw / README.en.md
Last active Oct 18, 2021
How to run Windows 10 on ARM or Ubuntu for ARM64 in QEMU on Apple Silicon Mac
View README.en.md

How to run Windows 10 on ARM or Ubuntu for ARM64 in QEMU on Apple Silicon Mac

Here is easy steps to try Windows 10 on ARM or Ubuntu for ARM64 on your Apple Silicon Mac. Enjoy!

NOTE: that this is current, 10/1/2021 state.

Running Windows 10 on ARM

  1. Install Xcode from App Store or install Command Line Tools on your Mac
@Barneybook
Barneybook / Telegram_it_group_list.md
Last active Sep 25, 2021
Telegram 資訊相關 群組清單
View Telegram_it_group_list.md
@ccwang002
ccwang002 / 0_Background.md
Last active May 27, 2021
Lab Coding Instructions for Beginners
View 0_Background.md

[TOC]

Lab Guide for Coding Beginners

亮亮(@ccwang002)| Mar, 2015 | CC 3.0 BY license

如果內容有誤,你可以用任何管道發訊息轟炸我,或用底下的 gist comment 留言。

學習方式

每個檔案都會是一個主題,主題底下會列出一些資源。資源的最後會有一個學習目標,方便讓你評估自己學到什麼程度。學習目標會給一個明確的任務,我盡量讓它能跟(宅宅的)日常生活結合。通常只要完成前一、二個目標就行了,這也不是功課所以不一定要給我看。如果你不介意給我看,我會分享我主觀的建議,但大部份的任務是沒有絕對的正確答案。只要能解決問題都是好方法。

@phrawzty
phrawzty / 2serv.py
Last active Oct 15, 2021
simple python http server to dump request headers
View 2serv.py
#!/usr/bin/env python2
import SimpleHTTPServer
import SocketServer
import logging
PORT = 8000
class GetHandler(SimpleHTTPServer.SimpleHTTPRequestHandler):
@leonjza
leonjza / netcat.py
Last active Sep 24, 2021
Python Netcat
View netcat.py
import socket
class Netcat:
""" Python 'netcat like' module """
def __init__(self, ip, port):
self.buff = ""
self.socket = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
@rodneyrehm
rodneyrehm / gist:40e7946c0cff68a31cea
Last active Oct 12, 2021
Diagrams for Documentation
View gist:40e7946c0cff68a31cea

some tools for diagrams in software documentation

Diagrams For Documentation

Obvious Choices

ASCII

@sckalath
sckalath / linux_privesc
Last active Oct 4, 2021
Linux Privilege Escalation Techniques
View linux_privesc
// Determine linux distribution and version
cat /etc/issue
cat /etc/*-release
cat /etc/lsb-release
cat /etc/redhat-release
// Determine kernel version - 32 or 64-bit?
cat /proc/version
uname -a
uname -mrs
@branneman
branneman / better-nodejs-require-paths.md
Last active Oct 18, 2021
Better local require() paths for Node.js
View better-nodejs-require-paths.md

Better local require() paths for Node.js

Problem

When the directory structure of your Node.js application (not library!) has some depth, you end up with a lot of annoying relative paths in your require calls like:

const Article = require('../../../../app/models/article');

Those suck for maintenance and they're ugly.

Possible solutions

@mzabriskie
mzabriskie / README.md
Last active Oct 8, 2021
Check git status of multiple repos
View README.md

If you're like me you have a dir like ~/Workspace/Github where all your git repos live. I often find myself making a change in a repo, getting side tracked and ending up in another repo, or off doing something else all together. After a while I end up with several repos with modifications. This script helps me pick up where I left off by checking the status of all my repos, instead of having to check each one individually.

Usage:

git-status [directory]

This will run git status on each repo under the directory specified. If called with no directory provided it will default to the current directory.