Skip to content

Instantly share code, notes, and snippets.

View Regenhardt's full-sized avatar

Marlon Regenhardt Regenhardt

  • Softfair
  • Terra
View GitHub Profile
@hl2guide
hl2guide / python_fix_warnings_invalid_distribution.md
Last active May 16, 2022 11:01
How to fix Python when you get messages like: WARNING: Ignoring invalid distribution -ip (c:\python39\lib\site-packages)

How to fix Python when you get messages like:

WARNING: Ignoring invalid distribution -ip (c:\python39\lib\site-packages)

Since Python is messy in the way it handles packages you sometimes need this fix.

This can happen when a package fails to install (reason may be permissions based).

Steps for Windows OS

@DanielSmon
DanielSmon / New MS Teams Profile.cmd
Last active April 29, 2024 19:23
For running multiple MS Teams accounts side by side. Save this with the name of the MS Teams profile you wish to use. When launched, a folder will be created in your user profile. See https://danielsmon.com/2020/04/02/multiple-ms-teams-accounts-on-the-desktop/.
@ECHO OFF
REM Uses the file name as the profile name
SET MSTEAMS_PROFILE=%~n0
ECHO - Using profile "%MSTEAMS_PROFILE%"
SET "OLD_USERPROFILE=%USERPROFILE%"
SET "USERPROFILE=%LOCALAPPDATA%\Microsoft\Teams\CustomProfiles\%MSTEAMS_PROFILE%"
REM Ensure there is a downloads folder to avoid error described at
@lisardggY
lisardggY / Fluent Cast
Last active May 16, 2019 09:15
For casting an object as part of a Fluent expression without having to put annoying parentheses around casting expressions.
public static T As<T>(this object objectToCast)
{
return objectToCast is T typedObject ? typedObject : default;
}
@JamesMGreene
JamesMGreene / gitflow-breakdown.md
Last active April 30, 2024 14:11
`git flow` vs. `git`: A comparison of using `git flow` commands versus raw `git` commands.

Initialize

gitflow git
git flow init git init
  git commit --allow-empty -m "Initial commit"
  git checkout -b develop master

Connect to the remote repository