Skip to content

Instantly share code, notes, and snippets.

View abdmun8's full-sized avatar
:octocat:
Focusing

Abdul Munim abdmun8

:octocat:
Focusing
View GitHub Profile
@abdmun8
abdmun8 / SendTestBot.php
Created May 30, 2018 04:52 — forked from banghasan/SendTestBot.php
Test Send Message Pakai PHP - Curl
<?php
/*
Simple File untuk Ngetes Send Pesan ke Bot
Memiliki banyak kegunaan dan tujuan
misalnya ngetes pesan dengan format tertentu, line break, char khusus, dll.
bisa dipergunakan juga untuk test hosting, cronjob, dan segala test lainnya.
Jika menggunakan mode GET :
@abdmun8
abdmun8 / LNGoogleCalSync-Launcher.applescript
Created August 11, 2019 18:23 — forked from oliveratgithub/LNGoogleCalSync-Launcher.applescript
AppleScript to launch the "Lotus Notes to Google Calendar Synchronizer"-GUI (LNGoogleCalSync) in the background on macOS
---- This AppleScript is written to work with the Lotus Notes to Google Calendar Synchronizer on macOS
---- http://lngooglecalsync.sourceforge.net
---- AppleScript by oliveratgithub
-- Change below path to match the location of the "lngsync.sh" file!
property lngsyncPath : "/Applications/LNGoogleCalSync/"
---- You don't need to care about the code below this line ;-)
property lngsyncFilePath : lngsyncPath & "lngsync.sh"
@abdmun8
abdmun8 / emojis.json
Created August 11, 2019 18:23 — forked from oliveratgithub/emojis.json
Emoji-list with emojis, names, shortcodes, unicode and html entities [massive list]
{
"emojis": [
{"emoji": "👩‍👩‍👧‍👧", "name": "family_mothers_two_girls", "shortname": "", "unicode": "", "html": "&#128105;&zwj;&#128105;&zwj;&#128103;&zwj;&#128103;", "category": "p", "order": ""},
{"emoji": "👩‍👩‍👧‍👦", "name": "family_mothers_children", "shortname": "", "unicode": "", "html": "&#128105;&zwj;&#128105;&zwj;&#128103;&zwj;&#128102;", "category": "p", "order": ""},
{"emoji": "👩‍👩‍👦‍👦", "name": "family_mothers_two_boys", "shortname": "", "unicode": "", "html": "&#128105;&zwj;&#128105;&zwj;&#128102;&zwj;&#128102;", "category": "p", "order": ""},
{"emoji": "👨‍👩‍👧‍👧", "name": "family_two_girls", "shortname": "", "unicode": "", "html": "&#128104;&zwj;&#128105;&zwj;&#128103;&zwj;&#128103;", "category": "p", "order": ""},
{"emoji": "👨‍👩‍👧‍👦", "name": "family_children", "shortname": "", "unicode": "", "html": "&#128104;&zwj;&#128105;&zwj;&#128103;&zwj;&#128102;", "category": "p", "order": ""},
{"emoji": "👨‍👩‍👦‍👦", "name": "family_two_boys", "shortname": "", "unicode": "", "html": "&#128104;&zw
@abdmun8
abdmun8 / docker-mysql.md
Last active April 26, 2020 03:47
Setup mysql on docker

Setup mysql 5.6 on docker container

if you want to use other version just change the '5.6' source: https://hub.docker.com/r/mysql/mysql-server

Pull mysql 5.6 images

docker pull mysql/mysql-server:5.6

Run container bind port 3306 & set password

docker run --name=mysql5.6 -p 3306:3306 -e MYSQL_ROOT_HOST=% -e MYSQL_ROOT_PASSWORD=root -d mysql/mysql-server:5.6

Login to mysql

docker exec -t mysql5.6 mysql -uroot -proot

@abdmun8
abdmun8 / Error on 'react-native start' or 'npm start' or 'yarn start'
Last active July 6, 2020 03:00
Error on 'react-native start' / 'npm start' / 'yarn start'
\node_modules\metro-config\src\defaults\blacklist.js
FROM
var sharedBlacklist = [
/node_modules[/\\]react[/\\]dist[/\\].*/,
/website\/node_modules\/.*/,
/heapCapture\/bundle\.js/,
/.*\/__tests__\/.*/
];
@abdmun8
abdmun8 / delete_file.php
Created August 4, 2020 14:41
Delete file older than 7 days using php
<?php
// save in directory where file exists
$dir = __DIR__;
$files = scandir($dir);
$date = date_create();
$limit = strtotime('-7 day', date_timestamp_get($date));
$total = 0;
$count = 0;
foreach ($files as $key => $file) {
@abdmun8
abdmun8 / iterm2.md
Created May 31, 2021 01:43 — forked from squarism/iterm2.md
iterm2 cheatsheet

Tabs and Windows

Function Shortcut
New Tab + T
Close Tab or Window + W (same as many mac apps)
Go to Tab + Number Key (ie: ⌘2 is 2nd tab)
Go to Split Pane by Direction + Option + Arrow Key
Cycle iTerm Windows + backtick (true of all mac apps and works with desktops/mission control)
# paste in your console after login
var ids = ['FORCE_ENROLLMENT','freezeSearch'];ids.forEach(e => {var i = document.getElementById(e); i.style.display = 'none'});
@abdmun8
abdmun8 / delete-files-older-than-7-days.md
Last active May 26, 2022 16:56
Delete Files older than 7 days windows

Delete Files older than 7 days on windows

ForFiles /p "C:\path\to\folder" /s /d -7 /c "cmd /c del /q @file"

or

ForFiles -p "C:\path\to\folder" -s -m *.bak -d -7 -c "Cmd /C del @FILE"
@abdmun8
abdmun8 / commit-how-to.md
Last active January 13, 2022 00:27
Git commit how to

Background

By writing good commits, you are simply future-proofing yourself. You could save yourself and/or coworkers hours of digging around while troubleshooting by providing that helpful description.

To come up with thoughtful commits, consider the following:

  • Why have I made these changes?
  • What effect have my changes made?
  • Why was the change needed?
  • What are the changes in reference to?