Skip to content

Instantly share code, notes, and snippets.

View raihan71's full-sized avatar
🏠
Working from home

Raihan Nismara raihan71

🏠
Working from home
View GitHub Profile
@raihan71
raihan71 / Ajax-Instructions.md
Created December 5, 2017 02:34 — forked from msurguy/Ajax-Instructions.md
Morris bar charts with AJAX (Laravel)

Did I hear you wanted AJAX charts instead of hard coded? You got it.

Follow this guide to integrate bar chart reports into your Laravel application with AJAX. Reports like the following come with this guide:

  • Total number of Orders by day
  • Total number of Users subscribed by day
  • etc

The library used for the charts is: http://www.oesmith.co.uk/morris.js/

@raihan71
raihan71 / multi-git-win.md
Created January 14, 2019 07:16 — forked from rosswd/multi-git-win.md
Setting up a Github and Bitbucket account on the same computer on Mac OS. Now with a guide for Windows 10.

Setting up github and bitbucket on the same computer (Windows)

Guide for Windows

mix3d asked for some help using this guide with windows so here we go. This was tested with Windows 10. Run all commands in Git Bash once it's installed.

Github will be the main account and bitbucket the secondary.

Git for Windows

  • Download and install Git for Windows
  • In the installer, select everything but decide if you want a desktop icon (2nd step)
@raihan71
raihan71 / readme.md
Created August 7, 2019 06:05 — forked from huenisys/readme.md
encode private RSA key for gitlab error: "Enter passphrase for /dev/fd/63" error

Encode your private RSA key

$ cat my_private_key | base64 -w0 
# -w0 to avoid newlines

Add the base64 string to your project variables. Use it in your .gitlab-ci.yml

@raihan71
raihan71 / nginx.conf
Created October 4, 2019 06:26 — forked from calebwoods/nginx.conf
Sample Nginx config for deployment of Angular.js app
server { listen 80;
server_name example.com;
access_log /var/log/example.com/nginx.access.log;
error_log /var/log/example.com/nginx.error.log;
root /var/www/apps/example.com/public;
charset utf-8;
location / {
rewrite ^ https://$host$request_uri? permanent;
}
@raihan71
raihan71 / js-advanced.md
Last active December 31, 2020 04:15
This is about my notes and gists about course from Brad Traversy - "Modern JS From The Beginning"

Modern javascript from the beginning

Useful Syntax

  • console.table(data) = visualized data with ta
  • typeof data = get to know type data of the variable
  • Number(string) = convert number any type to type of number
  • String(number) = convert number any type to type of string
  • toFixed(decimal) = to add custom decimal number
  • parseInt(string or number) = just parse to the integer
  • parseFloat(string or number) = parse to the float type
@raihan71
raihan71 / order-status.ts
Created October 31, 2019 04:28
Order status of marketplace
export class OrderStatus {
static get(status:string):string {
let ostatus:string;
switch (status) {
case "pending": {
ostatus = 'Pesanan Pending';
break;
}
@raihan71
raihan71 / css-advanced.md
Created January 7, 2020 08:08
This is about my notes and gists about the course of Academind "CSS - The Complete Guide 2020"

Bismillah

Windows 10 Fall Creators Update - Installing Node.js on Windows Subsystem for Linux (WSL)

Windows just released the windows subsystem for linux feature to the public with its latest windows fall creator update, if you are not familiar with this feature it allows you to run linux binaries natively on windows - F.A.Q.

Enabling WSL

The feature is not enabled by default and you need to activate it, you can do it via powershell (with admin rights):

Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux
@raihan71
raihan71 / circleci.md
Last active May 27, 2020 13:21
This is how I implemented circleci with vps

Steps to configure circle with vps

CircleCI >> Section

  • Go to circleci[dot]com
  • then login using your favorite git services
  • choose project you want setup
  • start configure circle.yml it will create .circleci/config.yml
  • then you'll see the test failed don't panic becuase it's normal at first
Mithun +91-9945610123 H.A13:28
users
id, username, email, password
roles: id, role_name, status
users_role_tbl: id, userId, roleId
Mithun H.A13:29
pages: home, about, contact
pages: id, pagename, status
3 pages can be accessed by superuser
2 pages from admin