Skip to content

Instantly share code, notes, and snippets.

View frullah's full-sized avatar
🎯
Focusing

Fajarullah frullah

🎯
Focusing
View GitHub Profile
#!/bin/bash
# requirements:
# - pageres-cli (https://github.com/sindresorhus/pageres-cli)
# CLI website screenshot tool
# - crunch (https://github.com/chrissimpkins/Crunch)
# PNG image optimizer
#
# usage:
# see https://github.com/sindresorhus/pageres-cli#usage
# don't use `--format` argument, let script do it automatically
function logic() {
let data = {}
// kode pemrosesan data ...
debugger
}
function logic() {
let data = {}
// kode pemrosesan data ...
console.log('-----------------------')
console.log('data setelah diproses')
console.log(data)
console.log('-----------------------')
}
@frullah
frullah / Guardfile
Created October 5, 2020 04:39
rails additional rspec guard watch
# factories
begin
require "active_support/inflector"
watch(%r{spec/factories/(.+).rb}) do |match|
"#{rspec.spec_dir}/models/#{match[1].singularize}_spec.rb"
end
end
@frullah
frullah / debian-10-oci8-install.sh
Last active December 29, 2020 00:25
Oracle instantclient installation script
#!/bin/bash
set -e
MAJOR_VERSION=21
MINOR_VERSION=1
INSTANTCLIENT_DIRNAME=instantclient_${MAJOR_VERSION}_${MINOR_VERSION}
INSTANTCLIENT_PATH=/opt/${INSTANTCLIENT_DIRNAME}
INSTANTCLIENT_DOWNLOAD_PATH=/tmp/${INSTANTCLIENT_DIRNAME}
@frullah
frullah / web-design-inspirations.txt
Last active September 4, 2020 13:13
web design inspirations
https://www.mint.com/
https://www.mobify.com/
https://alpha-creative.vuetifyjs.com
http://www.templatemonsterpreview.com/demo/94212.html?_ga=2.104293187.2122524184.1599223583-2013893291.1599223583
https://www.groovecommerce.com/
@frullah
frullah / fix.php
Created August 6, 2020 19:22
Code fix for my friends
<?php
if (is_numeric($data1) && is_numeric($data2)) {
return $data1*$data2;
} else {
return 0;
}
@frullah
frullah / gist:9d0840a5241cd1cbe20491060de0d206
Created July 30, 2020 19:45
rubocop 0.88.0 fix warning
Layout/EmptyLinesAroundAttributeAccessor:
Enabled: false
Layout/SpaceAroundMethodCallOperator:
Enabled: false
Lint/DeprecatedOpenSSLConstant:
Enabled: false
Lint/DuplicateElsifCondition:
@frullah
frullah / .rubocop.yml
Last active August 22, 2020 06:28
rails api additional setup
# version 0.88.0
AllCops:
Exclude:
- 'node_modules/**/*'
- 'vendor/**/*'
- 'bin/*'
- 'db/*_schema.rb'
- 'db/schema.rb'
- 'config/spring.rb'
@frullah
frullah / Gemfile
Created July 30, 2020 19:02
rails additional setup
group :development, :test do
gem 'guard-rspec', require: false
gem 'rspec-rails', '~> 4.0.1'
end
group :development do
gem 'rubocop', '~> 0.88.0', require: false
gem 'spring-commands-rspec'
gem 'spring-commands-rubocop'
end