Skip to content

Instantly share code, notes, and snippets.

View nafiesl's full-sized avatar

Nafies Luthfi nafiesl

View GitHub Profile
@nafiesl
nafiesl / Preferences.sublime-settings
Created January 20, 2017 00:28
My Sublime User Preferences on 2017-01-20.08.27
{
"always_show_minimap_viewport": true,
"auto_complete": true,
"bold_folder_labels": true,
"caret_extra_bottom": 3,
"caret_extra_top": 3,
"caret_extra_width": 2,
"caret_style": "phase",
"close_windows_when_empty": false,
"color_scheme": "Packages/User/Facebook.tmTheme",
@nafiesl
nafiesl / .bash_aliases
Last active November 10, 2021 03:57
My .bash_aliases
# Shortcuts
alias hisgrep='history | grep'
alias syslog='sudo tail -f /var/log/kern.log'
alias aliasopen='vim ~/.bash_aliases'
alias editweb='vim routes/web.php'
alias aliassource='source ~/.bash_aliases'
alias hostsopen='sudo vim /etc/hosts'
alias neth='sudo nethogs ppp0'
alias dial='sudo wvdial --config=wvdial.conf'
alias dialg='sudo wvdial --config=gwvdial.conf'

My Development Setup

OS : Linux mint 17.3

Local Servers

  • Apache
  • Mariadb
  • Php 7.0

Dev Tools

@nafiesl
nafiesl / composer.lock
Created July 11, 2017 10:25
example nesbotcarbon 1.20.0
{
"_readme": [
"This file locks the dependencies of your project to a known state",
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
"This file is @generated automatically"
],
"content-hash": "fd10a4c22ee66682e2b6fb719cba3ead",
"packages": [
{
"name": "nesbot/carbon",
@nafiesl
nafiesl / controller-01.php
Last active July 20, 2017 10:19
Laravel Log Viewer
<?php
// app/Http/Controllers/LogFilesController.php
namespace App\Http\Controllers;
class LogFilesController extends Controller
{
public function index()
{
@nafiesl
nafiesl / Default (Linux).sublime-keymap
Last active November 5, 2017 06:04
My sublime-text custom keymap
[
{ "keys": ["ctrl+k", "ctrl+t"], "command": "title_case" },
{ "keys": ["ctrl+shift+g"], "command": "find_all_under" },
{ "keys": ["ctrl+shift+down"], "command": "duplicate_line" },
{ "keys": ["ctrl+shift+up"], "command": "duplicate_line" },
{ "keys": ["ctrl+alt+down"], "command": "select_lines", "args": {"forward": true} },
{ "keys": ["ctrl+alt+up"], "command": "select_lines", "args": {"forward": false} },
{ "keys": ["shift+alt+up"], "command": "swap_line_up" },
{ "keys": ["shift+alt+down"], "command": "swap_line_down" },
{ "keys": ["ctrl+shift+tab"], "command": "reindent", "args": {"single_line": false} },
@nafiesl
nafiesl / Preferences.sublime-settings
Created November 5, 2017 06:02
My sublime-text user preferences (ubuntu 16.04)
{
"always_show_minimap_viewport": true,
"auto_complete": true,
"bold_folder_labels": true,
"caret_extra_bottom": 3,
"caret_extra_top": 3,
"caret_extra_width": 2,
"caret_style": "phase",
"close_windows_when_empty": false,
"color_scheme": "Packages/User/Facebook-1.tmTheme",
@nafiesl
nafiesl / phpfmt.sublime-settings
Last active May 21, 2019 07:29
my phpfmt.sublime-settings
{
"format_on_save": true,
"passes":
[
"TightConcat",
"RestoreComments",
"AlignGroupDoubleArrow",
"AlignPHPCode",
"SortUseNameSpace"
],
@nafiesl
nafiesl / codeship-setup-commands-laravel-mysql.txt
Last active February 23, 2021 13:07
Codeship Setup Commands for Laravel that uses MySQL Database
phpenv local 7.0
echo "memory_limit = 512M" >> /home/rof/.phpenv/versions/$(phpenv version-name)/etc/php.ini
# install dependencies
COMPOSER_HOME=${HOME}/cache/composer
composer install --prefer-dist --no-interaction
# set up environment variables
touch .env
echo "APP_ENV=testing" >> .env
echo "APP_DEBUG=true" >> .env
echo "APP_KEY=base64:sQPFP80eWJQGo0SDPc+M2Tib+GLUocRYRw4RLsfM27I=" >> .env
##
# 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.
#