Skip to content

Instantly share code, notes, and snippets.

View panekj's full-sized avatar
:shipit:
mentally offline

Jakub Panek panekj

:shipit:
mentally offline
View GitHub Profile
variable "RUST_VERSION" {
default = "1.75"
}
variable "PACKAGE_NAME" {
default = "lapce-nightly"
}
variable "PACKAGE_VERSION" {
default = "nightly"
local wezterm = require 'wezterm'
return {
ssh_domains = {
{
name = "altex",
remote_address = "altex",
username = "pj",
},
{
@panekj
panekj / alpine.patch
Created July 31, 2021 21:15
Patch for PowerShell/PowerShell build module to allow cross compile to arm/arm64 Alpine
diff --git a/build.psm1 b/build.psm1
index 6028c5fdc..531116d47 100644
--- a/build.psm1
+++ b/build.psm1
@@ -298,6 +298,8 @@ function Start-PSBuild {
# We do not use ValidateScript since we want tab completion
# If this parameter is not provided it will get determined automatically.
[ValidateSet("alpine-x64",
+ "alpine-arm",
+ "alpine-arm64",
#!/bin/sh
export PS_VERSION=$1
export PS_PACKAGE=powershell-${PS_VERSION}-linux-alpine-x64.tar.gz
export PS_PACKAGE_URL=https://github.com/PowerShell/PowerShell/releases/download/v${PS_VERSION}/${PS_PACKAGE}
export PS_INSTALL_VERSION=$PS_VERSION
cd /tmp/
wget ${PS_PACKAGE_URL}
export PS_INSTALL_FOLDER=/opt/microsoft/powershell/$PS_INSTALL_VERSION
mkdir -p ${PS_INSTALL_FOLDER}
tar zxf /tmp/${PS_PACKAGE} -C ${PS_INSTALL_FOLDER} -v
BEGIN MESSAGE.
WX6Cd4B52vicwKl K7wA3f7UADHqJqp tNNk6zJmOtUC03y nQtqaFprUU0xgiL
Mu2WklrrOfNUlkc PTlJLBWBIqXTCKq 6Xr2MZHgg6tG8ds Wwte5XD5xPU8guE
aowbphTgRPBXw5M mRLlz9bCIdWWCwn MgPWrR3ksd8sXpo I3qjtEwO2jjMwf4
FBVXQJhnbc29VCH vjFsKDUHoKaH7Uc k2HeU21.
END MESSAGE.
asnp Citrix*
while($true){ `
Get-BrokerSession -SessionState Disconnected -AdminAddress hostname | ForEach-Object -Process { `
$time = ( ( Get-Date ) - ( $_.SessionStateChangeTime ) ).Hours ; if ( $time -gt 6 -and $_.UserName -ne "domain\user") { `
$_ | Stop-BrokerSession ; $_.UserName | Out-File -FilePath "C:\Windows\temp\licence.log" -Append `
} `
} ; Start-Sleep -Seconds 1800 `
}
// SSPR Button Start
function ssprButton() {
$("a#loginBtn").ready(function(){
$('a#loginBtn').after('<br><a id="ssprBtn" href="https://passwordreset.microsoftonline.com/?whr=domain.tld" target="_blank" class="button forms-authentication-button last-child default">Password Reset</a>');
});
setTimeout(function(){
if(document.getElementById('ssprBtn') != null){
clearInterval(timer);
}
}, 500);

Keybase proof

I hereby claim:

  • I am panekj on github.
  • I am panekj (https://keybase.io/panekj) on keybase.
  • I have a public key ASDPIorntcD5WSyM9MnPuA_brA2QiK9ZFJkwvawLy77WwAo

To claim this, I am signing this object: