Skip to content

Instantly share code, notes, and snippets.

View annawinkler's full-sized avatar

Anna Rajendran annawinkler

View GitHub Profile
@annawinkler
annawinkler / DefaultBranchToMain.md
Last active March 15, 2021 23:54
Change your default branch to main in git

It's easy to change your default branch to main!

On the command line, in the directory for your repository, run these commands to make sure you have all of the changes pulled down to master, move master to main, and push the new main branch:

git checkout master
git pull
git branch -m master main
git push -u origin main
@annawinkler
annawinkler / LearningGo.md
Last active February 24, 2021 17:04
Learning Go
@annawinkler
annawinkler / NUC-Basics.md
Last active December 2, 2020 17:45
So you just got a NUC!

NUC Basics

So you just got a NUC! Lucky you! This document collects what I learned when I setup my Intel NUC with Ubuntu.

What will I need?

In addition to the NUC itself, I recommend getting the following hardware:

  • A USB drive (2GB or larger)
  • A USB keyboard and mouse.
  • A monitor to connect to, with the appropriate cable. I am connecting one monitor to a laptop and the NUC, so I decided to get an HDMI<->DisplayPort cable for the NUC so I can have both devices connected to a single monitor.
@annawinkler
annawinkler / icebreakers.md
Last active May 2, 2023 13:51
my favorite icebreaker questions
  • What's your favorite dessert?
  • If you could spend the weekend in any city which would you choose?
  • What's the most beautiful place you've ever seen?
  • Would you rather live by the beach or in the mountains?
  • What kind of vegetable are you?
  • What do you love about your hometown?
  • Where would you most like to travel?
  • If you could appear on any game show which would you choose?
  • What’s the most amazing weather you’ve seen?
  • What is your favourite ice cream?
@annawinkler
annawinkler / pycharm-docker-compose-breakpoint.md
Last active April 23, 2019 15:47
How do I set a breakpoint in my code in PyCharm with docker-compose?

This is a great question! I forget how IDEs have nice features like breakpoints. OK so let's assume you have already started your services via something like docker-compose up. Let's also assume you have already opened your project in PyCharm.

The next thing to do is to configure a remote interpreter for the project as described in the PyCharm documentation.

OK, this next bit is this interesting part. When you add a Run/Debug configuration, let's say you have a Flask application, add a Flask server. When you do this, you'll see the Python interpreter is the remote interpreter! Cool!

One note - because of this issue pipenv does not work for a remote interpreter. Use pip instead.

@annawinkler
annawinkler / rm_git_submodule
Last active January 11, 2019 19:00
remove a git submodule
git submodule deinit <path_to_submodule>
git rm <path_to_submodule>
git commit -m "Removed submodule "
rm -rf .git/modules/<path_to_submodule>
@annawinkler
annawinkler / CircleCI_and_DockerCompose.md
Created December 12, 2018 17:31
circleci and docker-compose

What versions work? version: "3.7" # did not work version: 3 # does not work (needs to be a string)

@annawinkler
annawinkler / Py3.6and3.7.md
Last active December 4, 2018 18:58
How to have python 3.6 and 3.7 on my mac coexist???

Try using brew for example if already using Python 3:

$ brew unlink python

Then install python 3.6.5:

$ brew install https://raw.githubusercontent.com/Homebrew/homebrew-core/f2a764ef944b1080be64bd88dca9a1d80130c558/Formula/python.rb

To get back to python 3.7.0 use:

@annawinkler
annawinkler / Google Cloud with Docker Notes.md
Last active October 10, 2018 19:19
How to create a google cloud compute instance from a docker image???