Skip to content

Instantly share code, notes, and snippets.

View jagdeepsingh's full-sized avatar

Jagdeep Singh jagdeepsingh

  • Mohali
View GitHub Profile
@jagdeepsingh
jagdeepsingh / README.md
Last active September 21, 2023 11:57
Set up macOS High Sierra 10.13.6

Set up macOS High Sierra 10.13.6

Open the terminal and type git. If it not installed, you will see a dialog box with a button to install it. Click on the button and git will be installed in a couple of minutes.

$ git --version
git version 2.15.2 (Apple Git-101.1)

Binary

A binary is a bitstring where number of bits is divisible by 8.

> binary = <<0, 1, 2>>
> byte_size binary
3

> String.valid? binary
@jagdeepsingh
jagdeepsingh / README.md
Last active May 23, 2017 08:02
Slim- Slim Framework source code

Slim

HTML elements

p Hello world
p = user.name
@jagdeepsingh
jagdeepsingh / README.md
Last active September 15, 2017 11:23
Stripe
@jagdeepsingh
jagdeepsingh / README.md
Last active March 13, 2023 12:38
Stripe Connect
@jagdeepsingh
jagdeepsingh / README.md
Last active May 12, 2017 12:33
Authorize.net Payment Gateway

Authorize.net

Create a sandbox account here.

You will get following credentials after the setup:

  • Login ID: 8R6TFt6m693
  • Transaction Key: 2x72742a3pDPq5Yy
  • Secret Key: Silon
@jagdeepsingh
jagdeepsingh / README.md
Last active May 18, 2017 07:58
WebMock- Library for stubbing and setting expectations on HTTP requests in Ruby

WebMock

Stub a request

Match request body and headers in stub.

let!(:stub_api_request) { stub_request(:post, 'http://api-host.com/path/') }
@jagdeepsingh
jagdeepsingh / README.md
Created May 24, 2017 07:30
zensend_ruby_api- APIs to send & receive SMS

zensend_ruby_api

Go to the home page of Zensend and click Try for free to setup a test account.

Enter the details asked and go to the next step. Enter your mobile number and verify it by entering the 6-digit code sent to your number.