You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A quick and simple script to change your Github user.email and user.name config details. Also a decent intro into scripting.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This is a simple script file that will allow a user to quickly switch their current github user.name and user.email. This is useful if you have multiple github accounts.
I use gh auth login to manage my github accs. Gh auth login will allow your device to push changes to a repo, and it seems that it will allow any user account on the device to do that.
But, if you don't want one account to be making changes on another repo it's important to manage the current github user credentials. This script helps with that.
Scripting:
First, read up on how to make script files on a mac here:
This doc will guide you through installing Mongo DB using WSL through the Command Line.
Most of the steps are listed out here, but this guide will trim them down and make it more straight forward for our needs. There is also 1 step that is not in the link above as well, which will be noted when we come across it.
This install is pretty different from previous versions of psql install instructions for windows. This install uses the WSL and Ubuntu shell.
We are installing this through the Ubuntu command line which is different from the other Ubuntu install instructions because those instructions use Ubuntu's GUI, which we don't have access to here.
NOTE: Since this is a service that is running on Ubuntu, you should be in the the Ubuntu file system when running these commands!
Typically we will always be working in the Windows PowerShell, but for this task we need to be in the Ubuntu app because we need to edit a file in the Ubuntu File System.
It is also highly recommended that you DO NOT edit a file in the Ubuntu system from Windows or through a Windows app as there will be errors, so we are doing this the right way by going through Ubuntu's commandline editor Nano.
At the end, this will add some coloring to your command line, and you command line will be formatted like this:
WSL stands for Windows Subsystem for Linux and it is a feature that you can enable on Windows 10 machines. It allows for you to add a Linux subsystem to your Windows machine. This subsystem will allow you to run programs and files in a POSIX or Unix-like environment, which solves many common issues that Windows users face when trying to run software that is developed for Linux.
Quick workaround for pushing your local database to heroku for windows machines.
Workaround for pushing to heroku database on windows machince.
Context:
The command heroku pg:push essentially executes two commands under the hood. First, it executes pg_dump, which makes a backup file of a specific database. Then, it pipes that file into pg_restore, where it takes that dump file and uses it to restore another database. The way we usually use it is to push a local database to a deployed heroku database.
The problem is that on windows, the command breaks while trying to pipe in the backup file from pg_dump to pg_restore, so we need to do these two commands manually.