Skip to content

Instantly share code, notes, and snippets.

@mfd
mfd / teams.sh
Last active December 12, 2025 06:39
Download any video from Microsoft Teams, SharePoint and OneDrive
2teams() {
NOW=$(date +"%Y-%m-%d_%H%M")
if [ ! -z $2 ] ; then
echo $NOW"_"$2.mp4
ffmpeg -i $1 -codec copy $NOW"_"$2.mp4
else
echo $NOW"_teamsvid".mp4
ffmpeg -i $1 -codec copy $NOW"_teamsvideo".mp4
fi
}
@jorrit
jorrit / IdentityModel logging.cs
Last active August 5, 2022 10:29
Enable .net identity model logging
IdentityModelEventSource.Logger.LogLevel = EventLevel.Verbose;
IdentityModelEventSource.ShowPII = true;
var listener = new TextWriterEventListener(new StreamWriter(Console.OpenStandardOutput())
{
AutoFlush = true,
});
listener.EnableEvents(IdentityModelEventSource.Logger, EventLevel.LogAlways);