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
Get-WindowsCapability -Online | ? Name -like 'OpenSSH*' | |
Add-WindowsCapability -Online -Name OpenSSH.Client~~~~0.0.1.0 | |
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 | |
: << 'COPYRIGHT_NOTICE' | |
MIT License | |
Copyright (c) 2022 ColhounTech Limited | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal | |
in the Software without restriction, including without limitation the rights |
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
#region Fields for Borderless Windows | |
private int borderSize = 0; | |
private bool _flatBorder = true; | |
private Size _restoreSize; | |
#endregion |
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
#region fix FormWindowState changes | |
private void SetupUIDefaults() | |
{ | |
// Don't change this: NoBorder with Resize Hack | |
var designSize = this.ClientSize; | |
this.FormBorderStyle = FormBorderStyle.Sizable; | |
this.Size = designSize; | |
this._restoreSize = designSize; // save for restore |
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
#region Min/Max/Restore for catching resize events to adjust form | |
private void BtnMin_Click(object sender, EventArgs e) | |
{ | |
_restoreSize = ClientSize; | |
this.WindowState = FormWindowState.Minimized; | |
AdjustForm(); | |
} | |
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
#region Window, No Border Hacks | |
protected override void WndProc(ref Message message) | |
{ | |
// Resize Window | |
if (message.Msg == WinUserH.WM_NCHITTEST) | |
{ |
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
#region Round Corners | |
private void RoundCorners(bool _isWindows11) | |
{ | |
if (_isWindows11) | |
{ | |
var attribute = DWMWINDOWATTRIBUTE.DWMWA_WINDOW_CORNER_PREFERENCE; | |
var preference = DWM_WINDOW_CORNER_PREFERENCE.DWMWCP_ROUND; | |
DwmSetWindowAttribute(this.Handle, attribute, ref preference, sizeof(uint)); |
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
sudo touch /etc/cloud/cloud-init.disabled | |
sudo systemctl disable lxd | |
sudo systemctl stop cloud-init | |
sudo systemctl disable cloud-init | |
sudo apt remove lvm2 -y --purge | |
sudo apt remove policykit-1 -y --purge |
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
grep -v "^#" $1 | grep -v "^\s*$" |
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
# /etc/sysctl.conf: | |
net.ipv6.conf.all.disable_ipv6 = 1 | |
net.ipv6.conf.default.disable_ipv6 = 1 | |
# reboot | |
sudo reboot | |
# sudo vi /etc/default/grub | |
# add |
NewerOlder