This file contains 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 function that receives a numerical range and for multiples of three prints “Fizz” instead of the number and for | |
# the multiples of five prints “Buzz”. For numbers which are multiples of both three and five, the function prints “FizzBuzz” | |
function FizzBuzz { | |
# Allow the use of standard PowerShell cmdlet features, in this instance the function is using Write-Verbose | |
[CmdletBinding()] | |
Param ( | |
# Specify that the $min variable is mandatory and must be an integer | |
[parameter(Mandatory=$true, ValueFromPipeline=$false)] | |
[int]$min, |
This file contains 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
import sys | |
import struct | |
def sid_to_str(sid): | |
""" Converts a hexadecimal string returned from the LDAP query to a | |
string version of the SID in format of S-1-5-21-1270288957-3800934213-3019856503-500 | |
This function was based from: http://www.gossamer-threads.com/lists/apache/bugs/386930 | |
""" | |
# The revision level (typically 1) |
This file contains 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
#!/bin/bash | |
dnf upgrade -y | |
# Set text scaling to 1.1 so the fonts are a bit larger | |
gsettings set org.gnome.desktop.interface text-scaling-factor 1.1 | |
# Add the minimize and maximize buttons on windows | |
gsettings set org.gnome.desktop.wm.preferences button-layout 'appmenu:minimize,maximize,close' | |
# Turn on the battery percentage | |
gsettings set org.gnome.desktop.interface show-battery-percentage true | |
# Show Desktop Icons | |
gsettings set org.gnome.desktop.background show-desktop-icons true |
This file contains 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
package main | |
import ( | |
"context" | |
"fmt" | |
"os/user" | |
"path" | |
"sync" | |
"k8s.io/apimachinery/pkg/api/errors" |