Skip to content

Instantly share code, notes, and snippets.

View isaku-dev's full-sized avatar

isaku.dev isaku-dev

View GitHub Profile
@isaku-dev
isaku-dev / git-collaborative-workflow.md
Created October 15, 2018 20:39 — forked from adamloving/git-collaborative-workflow.md
Simple Git workflow for collaborating on a project. I wrote this to help a co-worker learn Git (and help me remember after a year of working on my own).

Creating the change

$ git checkout -b my-feature

... modify code ....

$ git add <filename> 
$ git commit -m “my feature is this”
#
# Set the build number to the current git commit count.
# If we're using the Dev scheme, then we'll suffix the build
# number with the current branch name, to make collisions
# far less likely across feature branches.
# Based on: http://w3facility.info/question/how-do-i-force-xcode-to-rebuild-the-info-plist-file-in-my-project-every-time-i-build-the-project/
#
git=`sh /etc/profile; which git`
appBuild=`"$git" rev-list --all |wc -l`
if [ $CONFIGURATION = "Debug" ]; then
@isaku-dev
isaku-dev / GitHub-Forking.md
Created September 3, 2018 14:31 — forked from Chaser324/GitHub-Forking.md
GitHub Standard Fork & Pull Request Workflow

Whether you're trying to give back to the open source community or collaborating on your own projects, knowing how to properly fork and generate pull requests is essential. Unfortunately, it's quite easy to make mistakes or not know what you should do when you're initially learning the process. I know that I certainly had considerable initial trouble with it, and I found a lot of the information on GitHub and around the internet to be rather piecemeal and incomplete - part of the process described here, another there, common hangups in a different place, and so on.

In an attempt to coallate this information for myself and others, this short tutorial is what I've found to be fairly standard procedure for creating a fork, doing your work, issuing a pull request, and merging that pull request back into the original project.

Creating a Fork

Just head over to the GitHub page and click the "Fork" button. It's just that simple. Once you've done that, you can use your favorite git client to clone your repo or j

@isaku-dev
isaku-dev / browser.js
Created August 6, 2018 00:07 — forked from SmithKevin/browser.js
Finding a Quantcast tag using Puppeteer
const puppeteer = require('puppeteer');
const browserPromise = puppeteer.launch(
{timeout:60000, args:['--aggressive-cache-discard','--disable-cache', '--disable-application-cache']}
);
browserPromise.then(browser => {
return browser.version()
}).then(ver => console.log("Browser version " + ver));
@isaku-dev
isaku-dev / pandas cheat sheet.md
Created June 8, 2018 10:14 — forked from fabsta/pandas cheat sheet.md
pandas cheat sheet

[TOC]

Preliminaries/Import

import numpy as np
import matplotlib.pyplot as plt
import pandas as pd
from pandas import DataFrame, Series
@isaku-dev
isaku-dev / models.py
Created April 24, 2018 09:10 — forked from joneskoo/models.py
Django: Reusable model filtering: Using QuerySet.as_manager() properly
# http://www.dabapps.com/blog/higher-level-query-api-django-orm/
# Converted to use Django 1.8 QuerySet.as_manager()
# We inherit custom QuerySet to define new methods
class TodoQuerySet(models.query.QuerySet):
def incomplete(self):
return self.filter(is_done=False)
def high_priority(self):
return self.filter(priority=1)
@isaku-dev
isaku-dev / models.py
Created January 24, 2018 14:06 — forked from jacobian/models.py
An example of using many-to-many "through" to augment m2m relationships. See http://www.quora.com/How-do-you-query-with-a-condition-on-a-ManyToMany-model-in-Django for context.
from django.db import models
class Person(models.Model):
name = models.CharField(max_length=200)
groups = models.ManyToManyField('Group', through='GroupMember', related_name='people')
class Meta:
ordering = ['name']
def __unicode__(self):
@isaku-dev
isaku-dev / main.go
Created January 7, 2018 17:56 — forked from zoltan-nz/main.go
A simple golang web server with basic logging, tracing, health check, graceful shutdown and zero dependencies
package main
import (
"context"
"flag"
"fmt"
"log"
"net/http"
"os"
"os/signal"
@isaku-dev
isaku-dev / laravel-supervisor.md
Created December 14, 2017 18:02 — forked from vrajroham/laravel-supervisor.md
Installing Supervisor on AWS Elastic Beanstalk manually.

Installing Supervisor on AWS Elastic Beanstalk manually.

This gist may help you to install supervisor Manually on AWS Beanstalk host. I was enable to install and configure referring supervisor docs. Here are the steps by which I was able to use supervisor on my project.

Note: I have performed this steps on Laravel project and my instance was Debian powered. You can change according to your requirement.


  • Check python with easy_install is installed
  • Install supervisor > $ easy_install supervisor
  • Create directory for supervisor workers > mkdir /etc/supervisor/conf.d/
@isaku-dev
isaku-dev / celery.sh
Created December 13, 2017 22:23 — forked from amatellanes/celery.sh
Celery handy commands
/* Useful celery config.
app = Celery('tasks',
broker='redis://localhost:6379',
backend='redis://localhost:6379')
app.conf.update(
CELERY_TASK_RESULT_EXPIRES=3600,
CELERY_QUEUES=(
Queue('default', routing_key='tasks.#'),