Skip to content

Instantly share code, notes, and snippets.

View ronggur's full-sized avatar

Ronggur Mangaraja Habibun ronggur

View GitHub Profile
@ronggur
ronggur / deploy.sh
Created November 17, 2022 05:14 — forked from cagartner/deploy.sh
Laravel Push deploy Github actions example
#!/bin/sh
set -e
vendor/bin/phpunit
(git push) || true
git checkout production
git merge master
@ronggur
ronggur / 1-setup.md
Created October 14, 2020 11:16 — forked from troyfontaine/1-setup.md
Signing your Git Commits using GPG on MacOS Sierra/High Sierra

Methods of Signing with GPG

There are now two ways to approach this:

  1. Using gpg and generating keys
  2. Using Kryptonite by krypt.co

This Gist explains how to do this using gpg in a step-by-step fashion. Kryptonite is actually wickedly easy to use-but you will still need to follow the instructions

For using a GUI-based GIT tool such as Tower or Github Desktop, follow the steps here for signing with either GPG or Krypt.co.

@ronggur
ronggur / wait-el.js
Created October 1, 2020 04:22 — forked from chrisjhoughton/wait-el.js
Wait for an element to exist on the page with jQuery
var waitForEl = function(selector, callback) {
if (jQuery(selector).length) {
callback();
} else {
setTimeout(function() {
waitForEl(selector, callback);
}, 100);
}
};
@ronggur
ronggur / es6-element-ready.js
Created October 1, 2020 03:50 — forked from jwilson8767/es6-element-ready.js
Wait for an element to exist. ES6, Promise, MutationObserver
// MIT Licensed
// Author: jwilson8767
/**
* Waits for an element satisfying selector to exist, then resolves promise with the element.
* Useful for resolving race conditions.
*
* @param selector
* @returns {Promise}
*/
@ronggur
ronggur / sftp-new-user.sh
Created June 17, 2020 14:48 — forked from NichlasB/sftp-new-user.sh
Shell Script for Creating EasyEngine Server SFTP User
#!/bin/bash
# WARNING: This script must be run manually to create a new SFTP user. Remember to change the new user's password.
# NOTICE: Make sure first instance of PasswordAuthentication is set to "no" $ sudo nano /etc/ssh/sshd_config
# REQUIREMENT: Make sure bindfs is installed $ sudo apt-get -y install bindfs
####
## Gist: https://gist.github.com/NichlasB/9b9c79ff8e31f48ad19f652b71baf8f6
## Resource: https://easyengine.io/docs/chroot-sftp-easyengine/
## Resource: https://www.howtoforge.com/restricting-users-to-sftp-plus-setting-up-chrooted-ssh-sftp-debian-squeeze
@ronggur
ronggur / sftp-new-server.sh
Created June 17, 2020 14:48 — forked from NichlasB/sftp-new-server.sh
Shell Script for Setting Up SFTP Server with EasyEngine
#!/bin/bash
# WARNING: Only run this script once per server.
####
## Creating SFTP Users - Initial Setup for New Server
####
####
## Gist: https://gist.github.com/NichlasB/e938cddb7876fd74af09dc00ca537a2c