Skip to content

Instantly share code, notes, and snippets.

@RageshAntony
RageshAntony / App.def
Last active May 2, 2024 10:28
Kotlin/Native C Interop - Usage in Kotlin class
headers = nuklear.h App.h nuklear_glfw_gl2.h nk_defines.h /usr/include/GLFW/glfw3.h /usr/include/GLFW/glfw3native.h
compiler-options = -framework OpenGl
package = glfw
linkerOpts.osx = -L/opt/local/lib -L/usr/local/lib -lglfw
linkerOpts.linux = -L/usr/lib64 -L/usr/lib/x86_64-linux-gnu -lglfw -lGLU -lGL -lglut
linkerOpts.mingw = -lglfw
@DevSrSouza
DevSrSouza / build.gradle
Created February 6, 2019 19:54
Kotlin + Spigot 1.8.8 + Minecraft dev IntelliJ Plugin
plugins {
id 'java'
id 'org.jetbrains.kotlin.jvm' version '1.3.20'
id 'com.github.johnrengelman.shadow' version '4.0.3'
}
group = pluginGroup
version = pluginVersion
sourceCompatibility = 1.8
@pioug
pioug / index.js
Last active May 2, 2024 10:23
Errors to ignore on Sentry, likely caused by browsers/extensions/webviews
const ignoreErrors = [
/^No error$/,
/__show__deepen/,
/_avast_submit/,
/Access is denied/,
/anonymous function: captureException/,
/Blocked a frame with origin/,
/can't redefine non-configurable property "userAgent"/,
/change_ua/,
/console is not defined/,
@MauricioMoraes
MauricioMoraes / access_postgresql_with_docker.md
Last active May 2, 2024 10:21
Allow Docker Container Access to Host's Postgres Database on linux (ubuntu)

You have to do 2 things in order to allow your container to access your host's postgresql database

  1. Make your postgresql listen to an external ip address
  2. Let this client ip (your docker container) access your postgresql database with a given user

Obs: By "Host" here I mean "the server where docker is running on".

Make your postgresql listen to an external ip address

Find your postgresql.conf (in case you don't know where it is)

$ sudo find / -type f -name postgresql.conf

@seachai
seachai / gist:948ed1eeafa32ce03db6685edb879f71
Last active May 2, 2024 10:19
iTerm 2 Natural Text Editing Preset
On iTerm2 - Open Preferences > Profiles > Keys > Key Mappings > Presets > Select Natural Text Editing
- You can move a word backwards using Option ⌥ + ← and a word forwards using Option ⌥ + →
- Move to the start of the line using fn + ← and to the end of the line with fn + →.
- Also you can delete a word backwards using Option ⌥ + ⌫, delete the whole line using Command ⌘ + ⌫.
If the preset doesn't appear, reinstall iTerm2. If you installed it using Homebrew + Cask:
brew cask reinstall iterm2
@dhh
dhh / linux-setup.sh
Last active May 2, 2024 10:19
linux-setup.sh
# CLI
sudo apt update -y
sudo apt install -y \
git curl \
docker.io docker-buildx \
build-essential pkg-config autoconf bison rustc cargo clang \
libssl-dev libreadline-dev zlib1g-dev libyaml-dev libreadline-dev libncurses5-dev libffi-dev libgdbm-dev libjemalloc2 \
libvips imagemagick libmagickwand-dev mupdf mupdf-tools \
redis-tools sqlite3 libsqlite3-0 libmysqlclient-dev \
rbenv apache2-utils
@redmcg
redmcg / kubedf
Last active May 2, 2024 10:19
Bash script to show k8s PVC usage
#!/usr/bin/env bash
NODESAPI=/api/v1/nodes
function getNodes() {
kubectl get --raw $NODESAPI | jq -r '.items[].metadata.name'
}
function getPVCs() {
jq -s '[flatten | .[].pods[].volume[]? | select(has("pvcRef")) | '\
@notlin4
notlin4 / without-auth_e-book_tutorial_免登入電子書教學.md
Last active May 2, 2024 10:18 — forked from aliyaliu368/without-auth_e-book_tutorial_免登入電子書教學.md
教學用電子書與相關工具免登入教學 | 本指令碼用於繞過臺灣電子書與教學工具的前端身分驗證,達成不需要教師帳號即可使用。支援 翰林、南一、康軒、何嘉仁 四大出版社 | 請勿將本指令碼作為抄答案、侵權等惡意用途,使用本指令碼,請自行承擔所有後果與風險

教學用電子書與相關工具免登入教學

使用本指令碼即代表你同意本免責聲明

免責聲明

請勿將本指令碼作為抄答案、侵權等惡意用途,使用本指令碼,請「自行承擔」所有後果與風險。

簡介

本指令碼用於繞過臺灣電子書與教學工具的前端驗證,達成不需要教師帳號即可使用。

@lohhans
lohhans / README-PTBR.md
Last active May 2, 2024 10:16 — forked from PurpleBooth/README-Template.md
Um modelo para fazer um bom README.md

Título do projeto

Um parágrafo da descrição do projeto vai aqui

🚀 Começando

Essas instruções permitirão que você obtenha uma cópia do projeto em operação na sua máquina local para fins de desenvolvimento e teste.

Consulte Implantação para saber como implantar o projeto.

@rapinsa
rapinsa / block_gc.txt
Last active May 2, 2024 10:14 — forked from MewX/block_gc.txt
Block Adobe Hosts C:\drivers\etc\hosts
For anyone who might read this in the future, I've found the best solution to this problem. For some reason I didn't need to go through all these steps on my surface pro adobe programs, but my desktop gave me issues. So if you're still having issues after doing the following, read on.
If you just end the process in Task Manager, the pop-up comes back up eventually.
If you just delete the files in "C:\Program Files (x86)\Common Files\Adobe\AdobeGCClient" or the folder itself, they may just recreate themselves every day or two.
If you delete/disable the Adobe services or schedules in Task Scheduler, those may just come back too.
To solve these issues, I decided to make a .bat file that deletes every file in that AdobeGCClient folder (exact location may depend on your Adobe install folder) and schedule it to do this every time I log on/turn on my pc. So far that has worked for the past few days.