Skip to content

Instantly share code, notes, and snippets.

View fundter's full-sized avatar
💭
¯\_(ツ)_/¯

fundter

💭
¯\_(ツ)_/¯
View GitHub Profile
@fundter
fundter / docker-vm-ssh.sh
Created March 13, 2019 15:46
SSH into docker vm on macOS
screen ~/Library/Containers/com.docker.docker/Data/vms/0/tty
# Volumes are stored here
ls -l /var/lib/docker/volumes
@fundter
fundter / docker-compose.yml
Last active March 13, 2019 16:00
Docker compose file for CouchDB
version: "3.7"
services:
couchdb:
image: couchdb
container_name: couchdb
restart: "unless-stopped"
volumes:
- "data:/opt/couchdb/data"
- "settings:/opt/couchdb/etc"
@fundter
fundter / automatic-to-explicit-module.sh
Created February 1, 2019 22:47
Turn a non-modular jar into a modular jar (Java module)
# Generate module-info.java
jdeps --generate-module-info <output-path-for-module-info.java> <path-to-non-modular-jar>
# Compile the module-info.java
javac --patch-module <name-of-the-module>=<path-to-non-modular-jar> <path-to-module-info.java>
# Update jar with module-info
cd <directory-containing-module-info.class> # avoid path prefix to module-info for next command
jar uf <path-to-non-modular-jar> module-info.class
@fundter
fundter / deploy.sh
Last active January 30, 2019 09:00
Deploy jar file to local maven repository
mvn deploy:deploy-file -DgroupId=com.sample -DartifactId=sample -Dversion=47.11 -Dpackaging=jar -Dfile=/path/to/sample.jar -DrepositoryId=repository-id -Durl=file:/path/to/repo/
@fundter
fundter / SampleTest.m
Last active March 16, 2016 13:55
Simple XCTest base class to handle filesystem based tests
//
// SampleTest.m
//
#import "TestBase.h"
@interface DiscoveryTests : TestBase
@end