Skip to content

Instantly share code, notes, and snippets.

View hadanischal's full-sized avatar
🧑‍💻
Focusing

Nischal Hada hadanischal

🧑‍💻
Focusing
View GitHub Profile
@hadanischal
hadanischal / GitCommitEmoji.md
Created September 5, 2021 08:40 — forked from parmentf/GitCommitEmoji.md
Git Commit message Emoji
@hadanischal
hadanischal / charles-proxy-android.md
Created July 14, 2021 05:38 — forked from twaddington/charles-proxy-android.md
How to set up Charles Proxy for the Android Emulator.

Charles Proxy Android

Steps

1. Add the Network Security Configuration to your app

<network-security-config>
   <debug-overrides>
 
import UIKit
import EventKit
import EventKitUI
typealias EventsCalendarManagerResponse = (_ result: ResultCustomError<Bool, CustomError>) -> Void
class EventsCalendarManager: NSObject {
var eventStore: EKEventStore!
@hadanischal
hadanischal / heroku_pg_db_reset.md
Created May 18, 2020 13:09 — forked from zulhfreelancer/heroku_pg_db_reset.md
How to reset PG Database on Heroku?

How to reset PG Database on Heroku?

  • Step 1: heroku restart
  • Step 2: heroku pg:reset DATABASE (no need to change the DATABASE)
  • Step 3: heroku run rake db:migrate
  • Step 4: heroku run rake db:seed (if you have seed)

One liner

heroku restart; heroku pg:reset DATABASE --confirm APP-NAME; heroku run rake db:migrate

@hadanischal
hadanischal / git-tag-delete-local-and-remote.sh
Created May 13, 2020 10:16 — forked from mobilemind/git-tag-delete-local-and-remote.sh
how to delete a git tag locally and remote
# delete local tag '12345'
git tag -d 12345
# delete remote tag '12345' (eg, GitHub version too)
git push origin :refs/tags/12345
# alternative approach
git push --delete origin tagName
git tag -d tagName
@hadanischal
hadanischal / .swiftlint.yml
Created April 25, 2020 11:36 — forked from j0d5/.swiftlint.yml
Swiftlint configuration file
included:
excluded:
- Pods
- Cartography
- build
disabled_rules: # rule identifiers to exclude from running
# - cyclomatic_complexity
- trailing_whitespace
@hadanischal
hadanischal / postgres-brew.md
Created April 24, 2020 04:48 — forked from ibraheem4/postgres-brew.md
Installing Postgres via Brew (OSX)

Installing Postgres via Brew

Pre-Reqs

Brew Package Manager

In your command-line run the following commands:

  1. brew doctor
  2. brew update
//
// NavigationControllerExtension.swift
// SnackViewExample
//
// Created by Nischal Hada on 19/9/19.
// Copyright © 2019 Nischal Hada. All rights reserved.
//
import UIKit
//
// UIStackView+removeAll.swift
// SnackViewExample
//
// Created by Nischal Hada on 19/9/19.
// Copyright © 2019 Nischal Hada. All rights reserved.
//
import UIKit
@hadanischal
hadanischal / TouchID_for_sudo.txt
Created September 5, 2019 07:50 — forked from pich4ya/TouchID_for_sudo.txt
MacOS's TouchID for sudo in iTerm2
1. $ sudo vim /etc/pam.d/sudo
2. add this line on top of the content
auth sufficient pam_tid.so
3.
:w!
:q
4. works now for Terminal, but for iTerm 2, go to top menu