Skip to content

Instantly share code, notes, and snippets.

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

Septiyan Andika SeptiyanAndika

🏠
Working from home
View GitHub Profile
@SeptiyanAndika
SeptiyanAndika / update_opensea.py
Created April 30, 2022 00:03 — forked from sudo-owen/update_opensea.py
Update OpenSea metadata
import requests
import time
# change the address here to be your desired NFT
url = "https://api.opensea.io/asset/0xc17030798a6d6e1a76382cf8f439182eb0342d93/"
update_flag = "/?force_update=true"
ids = [ i for i in range(0, 180)]
for i in ids:
@SeptiyanAndika
SeptiyanAndika / hardhat-openzeppelin-project.md
Created December 18, 2021 21:59 — forked from alkavan/hardhat-openzeppelin-project.md
Hardhat and OpenZeppelin project bootstrap for Ethereum contract development

Install Instructions

Install Hardhat

npm install --save-dev hardhat

Initiate a new Hardhat project (in empty directory)

npx hardhat
@SeptiyanAndika
SeptiyanAndika / IDEX.sol
Created July 9, 2019 02:00 — forked from dominiek/IDEX.sol
IDEX Smart Contract
pragma solidity ^0.4.16;
contract Token {
bytes32 public standard;
bytes32 public name;
bytes32 public symbol;
uint256 public totalSupply;
uint8 public decimals;
bool public allowTransactions;
mapping (address => uint256) public balanceOf;
@SeptiyanAndika
SeptiyanAndika / redis_migrate.py
Created December 3, 2018 10:26 — forked from josegonzalez/redis_migrate.py
A simple script to migrate all keys from one Redis to another
#!/usr/bin/env python
import argparse
import redis
def connect_redis(conn_dict):
conn = redis.StrictRedis(host=conn_dict['host'],
port=conn_dict['port'],
db=conn_dict['db'])
return conn
@SeptiyanAndika
SeptiyanAndika / amazon-rekognition.md
Created July 7, 2018 08:26 — forked from alexcasalboni/amazon-rekognition.md
Amazon Rekognition - Python Code Samples

Amazon Rekognition - Python Code Samples

  1. Labels Detection
  2. Faces Detection
  3. Faces Comparison
  4. Faces Indexing
  5. Faces Search
@SeptiyanAndika
SeptiyanAndika / ExcelFormulas.js
Created March 22, 2018 17:21 — forked from pies/ExcelFormulas.js
Few Excel formulas - PMT, PPMT, XIRR - expressed in Javascript
/* Based on
* - EGM Mathematical Finance class by Enrique Garcia M. <[email protected]>
* - A Guide to the PMT, FV, IPMT and PPMT Functions by Kevin (aka MWVisa1)
*/
var ExcelFormulas = {
PVIF: function(rate, nper) {
return Math.pow(1 + rate, nper);
},
@SeptiyanAndika
SeptiyanAndika / dep.md
Created March 20, 2018 23:47 — forked from subfuzion/dep.md
Concise guide to golang/dep

Overview

This gist is based on the information available at golang/dep, only slightly more terse and annotated with a few notes and links primarily for my own personal benefit. It's public in case this information is helpful to anyone else as well.

I initially advocated Glide for my team and then, more recently, vndr. I've also taken the approach of exerting direct control over what goes into vendor/ in my Dockerfiles, and also work from isolated GOPATH environments on my system per project to ensure that dependencies are explicitly found under vendor/.

At the end of the day, vendoring (and committing vendor/) is about being in control of your dependencies and being able to achieve reproducible builds. While you can achieve this manually, things that are nice to have in a vendoring tool include:

@SeptiyanAndika
SeptiyanAndika / serverless.yml
Created January 16, 2018 04:03 — forked from jscattergood/serverless.yml
Creating a custom serverless resource for subscribing to SNS topics in another region
# Welcome to Serverless!
#
# Happy Coding!
service: cross-region-sns-subscriber
# Keep environment specific configurations in separate files
custom: ${file(config/${env:STAGE}.json)}
provider:
@SeptiyanAndika
SeptiyanAndika / 0-README.md
Created December 27, 2017 13:21 — forked from lstude/0-README.md
Add Indent / Outdent Functionality to Google Spreadsheets

This tutorial demonstrates how to add an "Indent Text" menu item to a Google spreadsheet so you can indent/outdent text.

  • When the "Indent Text" menu item is selected, any cells within a single column selection will be indented by 5 spaces.

  • You can increase or decrease the number of spaces the text is indented by changing the line below so that the "5" is changed to a larger or smaller number (depending on your preference):

newValues.push(['=CONCAT(REPT( CHAR( 160 ), 5),"' + values[i][0] + '")']);
@SeptiyanAndika
SeptiyanAndika / crimbook-on-ipfs.png
Created December 19, 2017 04:22 — forked from judsonmitchell/crimbook-on-ipfs.png
Publishing My App to IPFS
crimbook-on-ipfs.png