Skip to content

Instantly share code, notes, and snippets.

View NetanelBasal's full-sized avatar
🎯
Focusing

Netanel Basal NetanelBasal

🎯
Focusing
View GitHub Profile
@oanhnn
oanhnn / using-multiple-github-accounts-with-ssh-keys.md
Last active April 23, 2024 15:20
Using multiple github accounts with ssh keys

Problem

I have two Github accounts: oanhnn (personal) and superman (for work). I want to use both accounts on same computer (without typing password everytime, when doing git push or pull).

Solution

Use ssh keys and define host aliases in ssh config file (each alias for an account).

How to?

  1. Generate ssh key pairs for accounts and add them to GitHub accounts.
@FrankMerema
FrankMerema / rest.service.ts
Created June 22, 2018 09:00
Testing Angular component with api service in OnInit (Spectator)
import {HttpClient} from '@angular/common/http';
import {Injectable} from '@angular/core';
import {Observable} from 'rxjs/index';
export interface someObject {
}
@Injectable({
providedIn: 'root'
})