Skip to content

Instantly share code, notes, and snippets.

View miftahafina's full-sized avatar
🏠
Work from heaven

Miftah Afina miftahafina

🏠
Work from heaven
View GitHub Profile
puts "Afin"
@miftahafina
miftahafina / tar-cheat-sheet.sh
Last active May 28, 2021 03:59
Tar Linux Cheat Sheet
# Membuat arsip
tar -cvf arsip.tar ~/nama-folder
tar -cvzf arsip.tar.gz ~/nama-folder
tar -cvjf arsip.tar.bz2 ~/nama-folder
# Ekstrak arsip
tar -xvf arsip.tar
tar -xvf arsip.tar.gz
tar -xvf arsip.tar.bz2
@miftahafina
miftahafina / 51-usb-device.rules
Created January 10, 2021 13:27
Wiimote Wii remote wii motion plus on ubuntu
# https://www.gamingonlinux.com/forum/topic/3247/
# https://github.com/dolphin-emu/dolphin/blob/master/Data/51-usb-device.rules
# dir /etc/udev/rules.d/
#GameCube Controller Adapter
SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ATTRS{idVendor}=="057e", ATTRS{idProduct}=="0337", TAG+="uaccess"
#Wiimotes or DolphinBar
SUBSYSTEM=="hidraw*", ATTRS{idVendor}=="057e", ATTRS{idProduct}=="0306", TAG+="uaccess"
SUBSYSTEM=="hidraw*", ATTRS{idVendor}=="057e", ATTRS{idProduct}=="0330", TAG+="uaccess"
Notes:
- Disable ufw
or
sudo ufw allow 19000/tcp
sudo ufw allow 19001/tcp
sudo ufw reload
ref
@miftahafina
miftahafina / things.txt
Last active July 18, 2020 15:16
Things you should do after installing Ubuntu 20.04
Install zsh
Install chrome
Install gnome shell integration for chrome
https://chrome.google.com/webstore/detail/gnome-shell-integration/gphhapmejobijbbhgpjhcjognlahblep/related
sudo apt install gnome-tweaks
Install dash to panel gnome extension
@miftahafina
miftahafina / EasternArabic.php
Last active November 14, 2019 08:38
#Helper - Convert from western to eastern arabic numeral
<?php
namespace app\Helpers;
class EasternArabic
{
public static function convert($number, $process = false)
{
if ($process) {
$western = ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '.'];
@miftahafina
miftahafina / konfigurasi-droplet.txt
Last active November 10, 2019 04:01
Install Droplet Ubuntu 16.04
Setup droplet
# create droplet ubuntu 16.04
# setup private network
Edit via DO Dashboard
https://www.digitalocean.com/docs/networking/private-networking/how-to/enable/#ubuntu-16-04
# initial setup (including firewall)
https://www.digitalocean.com/community/tutorials/initial-server-setup-with-ubuntu-16-04

AWS EC2, Ubuntu 16.04, PHP 7.1, NGINX, Laravel 5.5, MariaDB 10.2, Composer

DISCLAIMER: I will avoid using generic keywords so that you're forced to name things yourself:

test, example, default, key, 10.174.75.99

latvija, pupper, elvisoctp, ilunimati-top-security, 10.10.10.1000000000
@miftahafina
miftahafina / after installing ubuntu.txt
Last active January 8, 2019 20:44
What you have to do after installing ubuntu
# Install ubuntu
# Update repository
sudo apt-get update
Update apps
# sudo apt-get dist-upgrade
# Install Google Chrome
- Install