Skip to content

Instantly share code, notes, and snippets.

View neesonqk's full-sized avatar
🎯
Focusing

N.z neesonqk

🎯
Focusing
View GitHub Profile
@ymjing
ymjing / Dockerfile
Created May 7, 2022 02:08
A minimal docker file for running Grasscutter
FROM azul/zulu-openjdk:17 AS builder
RUN apt-get update \
&& apt-get install -y --no-install-recommends git libprotobuf-dev \
&& git clone -b development --depth 1 https://github.com/Grasscutters/Grasscutter /work
WORKDIR /work
RUN export GRADLE_OPTS="-Dfile.encoding=utf-8" \
&& git submodule update --init \
@smola
smola / sdkman_oracle_jdk.sh
Last active June 26, 2024 11:56
Install Oracle JDK 8 for use with SDKMAN
#!/bin/bash
#
# Install Oracle JDK 8 for use with SDKMAN
#
set -eu
# This URL can be discovered using https://sites.google.com/view/java-se-download-url-converter
DOWNLOAD_URL="https://javadl.oracle.com/webapps/download/GetFile/1.8.0_331-b09/165374ff4ea84ef0bbd821706e29b123/linux-i586/jdk-8u331-linux-x64.tar.gz"
TARBALL="jdk-8u331-linux-x64.tar.gz"
@gamma
gamma / gradle4.rb
Last active May 4, 2022 13:27
Gradle 4 for homebrew
# cat > /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/gradle4.rb
# brew install --build-from-source gradle4
class Gradle4 < Formula
desc "Open-source build automation tool based on the Groovy and Kotlin DSL"
homepage "https://www.gradle.org/"
url "https://services.gradle.org/distributions/gradle-4.10.3-all.zip"
sha256 "336b6898b491f6334502d8074a6b8c2d73ed83b92123106bd4bf837f04111043"
# not needed in newer gradle releases
# bottle :unneeded
@imyelo
imyelo / frpc.service
Last active July 19, 2024 05:33
run frp client as a service on windows and ubuntu / debian
# 1. put frpc and frpc.ini under /usr/local/frpc/
# 2. put this file (frpc.service) at /etc/systemd/system
# 3. run `sudo systemctl daemon-reload && sudo systemctl enable frpc && sudo systemctl start frpc`
# Then we can manage frpc with `sudo service frpc {start|stop|restart|status}`
# See also: https://nosame.net/use-frp-to-reverse-proxy-your-nas/
# Alternative for server:
# - Offical: https://github.com/fatedier/frp/blob/a4cfab6/conf/systemd/frpc%40.service
[Unit]
@Silverbaq
Silverbaq / Server.kt
Created January 1, 2018 21:15
A simple socket-server written in Kotlin
package dk.im2b
import java.io.OutputStream
import java.net.ServerSocket
import java.net.Socket
import java.nio.charset.Charset
import java.util.*
import kotlin.concurrent.thread
@shoogle
shoogle / qt-without-xcode.md
Last active April 30, 2024 16:45
Qt without XCode - how to use Qt Creator for macOS software development without installing XCode

Qt without Xcode

How to use Qt Creator for software development on macOS without having to install Xcode

Justification

Qt refuses to install on macOS unless Apple's Xcode is installed beforehand. This is unfortunate because:

@eLement87
eLement87 / mqtt_tls_working.ino
Created December 10, 2017 13:12
ESP8266 Secure MQTT Connection with Client Certificate Authentication
#include <FS.h>
#include <ESP8266WiFi.h>
#include <WiFiClientSecure.h>
#include <PubSubClient.h>
#include <time.h>
// Insert your FQDN of your MQTT Broker
#define MQTT_SERVER "mqtt.srvx1.local"
const char* mqtt_server = MQTT_SERVER;
@xameeramir
xameeramir / default nginx configuration file
Last active July 12, 2024 07:24
The default nginx configuration file inside /etc/nginx/sites-available/default
# Author: Zameer Ansari
# You should look at the following URL's in order to grasp a solid understanding
# of Nginx configuration files in order to fully unleash the power of Nginx.
# http://wiki.nginx.org/Pitfalls
# http://wiki.nginx.org/QuickStart
# http://wiki.nginx.org/Configuration
#
# Generally, you will want to move this file somewhere, and start with a clean
# file but keep this around for reference. Or just disable in sites-enabled.
#
@gravitylow
gravitylow / codesign_gdb.md
Last active April 16, 2024 02:18 — forked from hlissner/codesign_gdb.md
Codesign gdb on macOS

If you are getting this in gdb on macOS while trying to run a program:

Unable to find Mach task port for process-id 57573: (os/kern) failure (0x5).
 (please check gdb is codesigned - see taskgated(8))
  1. Open Keychain Access
  2. In menu, open Keychain Access > Certificate Assistant > Create a certificate
  3. Give it a name (e.g. gdbc)