Skip to content

Instantly share code, notes, and snippets.

View gokaybiz's full-sized avatar
🌪️
Focusing

gokaybiz

🌪️
Focusing
View GitHub Profile
@asukakenji
asukakenji / 0-go-os-arch.md
Last active April 24, 2024 06:51
Go (Golang) GOOS and GOARCH

Go (Golang) GOOS and GOARCH

All of the following information is based on go version go1.17.1 darwin/amd64.

GOOS Values

GOOS Out of the Box
aix
android
@jevakallio
jevakallio / readme.md
Last active April 22, 2024 15:51
`adb pull` from app data directory without root access

TL;DR;

com.package.name is your app identifier, and the file path is relative to the app user's home directory, e.g. '/data/user/0/com.package.name.

adb shell run-as com.package.name cp relative/path/file.ext /sdcard
adb pull /sdcard/file.ext

See long explanation below.

@nash403
nash403 / SvgFragment.vue
Created June 30, 2021 09:13
Vue component that render raw SVG content like with `v-html` but without the need of an extra root element.
<script lang="ts">
import { VNodeData } from 'vue'
import { defineComponent } from '@vue/composition-api'
/**
* Use this component to render raw SVG content
* without the need to use the `v-html` directive
* which requires a parent node in Vue 2.x (ex: `<div v-html="..."></div>`).
* `<NSvgFragment :src="..." />` will directly render the svg tag with its content.
* */
@tegansnyder
tegansnyder / Preventing-Puppeteer-Detection.md
Created February 23, 2018 02:41
Preventing Puppeteer Detection

I’m looking for any tips or tricks for making chrome headless mode less detectable. Here is what I’ve done so far:

Set my args as follows:

const run = (async () => {

    const args = [
        '--no-sandbox',
        '--disable-setuid-sandbox',
        '--disable-infobars',
@senderle
senderle / hand-modify-pdf.md
Created September 23, 2020 15:03
So you want to modify the text of a PDF by hand

So you want to modify the text of a PDF by hand...

If you, like me, resent every dollar spent on commercial PDF tools, you might want to know how to change the text content of a PDF without having to pay for Adobe Acrobat or another PDF tool. I didn't see an obvious open-source tool that lets you dig into PDF internals, but I did discover a few useful facts about how PDFs are structured that I think may prove useful to others (or myself) in the future. They are recorded here. They are surely not universally applicable --
the PDF standard is truly Byzantine -- but they worked for my case.

@mmcdaris
mmcdaris / go_build_man.md
Last active March 21, 2024 09:59
going through the go build command

usage

go build: compiles the packages named by the import paths, along with their dependencies, the binary does not end up in $GOPATH/bin it gets created in the dirs

go build [-o output] [build flags] [packages]

If the [packages] are a list of .go files, build treats them as a list of source files specifying a single package.

@ryanfitz
ryanfitz / golang-nuts.go
Created December 2, 2012 22:45
two ways to call a function every 2 seconds
package main
import (
"fmt"
"time"
)
// Suggestions from golang-nuts
// http://play.golang.org/p/Ctg3_AQisl
@coreycoto
coreycoto / gist:6aa445806a832f7f7386
Last active February 2, 2024 11:50
Windows Boxstarter
cinst -y googlechrome
cinst -y firefox
cinst -y fiddler4
cinst -y atom
cinst -y 7zip
cinst -y paint.net
cinst -y git
cinst -y poshgit
cinst -y gitextensions
cinst -y wget
@henriquemoody
henriquemoody / http-status-codes.php
Last active January 26, 2024 10:29
List of HTTP status codes in PHP
<?php
/**
* Content from http://en.wikipedia.org/wiki/List_of_HTTP_status_codes
*
* You may also want a list of unofficial codes:
*
* 103 => 'Checkpoint',
* 218 => 'This is fine', // Apache Web Server
* 419 => 'Page Expired', // Laravel Framework
@AssisrMatheus
AssisrMatheus / #vscode-setup.md
Last active January 7, 2024 14:06
My optimized Visual Studio Code setup