Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CommitMono-NF(,-Mono,-Propo): Add version 3.1.0 #263

Merged
merged 1 commit into from
Nov 21, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
92 changes: 92 additions & 0 deletions bucket/CommitMono-NF-Mono.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
{
"version": "3.1.0",
"description": "Nerd Fonts patched 'CommitMono' Font family. (Monospace version, Nerd Fonts Symbol/Icon will be always 1 cell wide)",
"homepage": "https://github.com/ryanoasis/nerd-fonts",
"license": "MIT",
"url": "https://github.com/ryanoasis/nerd-fonts/releases/download/v3.1.0/CommitMono.zip",
"hash": "1ba8a0fa707298856c80ee2b8b9ac1dc1dd3dbfdc9c4a7d8ebfbc5f0b650df89",
"installer": {
"script": [
"$currentBuildNumber = [int] (Get-ItemProperty \"HKLM:\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\").CurrentBuildNumber",
"$windows10Version1809BuildNumber = 17763",
"$isPerUserFontInstallationSupported = $currentBuildNumber -ge $windows10Version1809BuildNumber",
"if (!$isPerUserFontInstallationSupported -and !$global) {",
" scoop uninstall $app",
" Write-Host \"\"",
" Write-Host \"For Windows version before Windows 10 Version 1809 (OS Build 17763),\" -Foreground DarkRed",
" Write-Host \"Font can only be installed for all users.\" -Foreground DarkRed",
" Write-Host \"\"",
" Write-Host \"Please use following commands to install '$app' Font for all users.\" -Foreground DarkRed",
" Write-Host \"\"",
" Write-Host \" scoop install sudo\"",
" Write-Host \" sudo scoop install -g $app\"",
" Write-Host \"\"",
" exit 1",
"}",
"$fontInstallDir = if ($global) { \"$env:windir\\Fonts\" } else { \"$env:LOCALAPPDATA\\Microsoft\\Windows\\Fonts\" }",
"if (-not $global) {",
" # Ensure user font install directory exists and has correct permission settings",
" # See https://github.com/matthewjberger/scoop-nerd-fonts/issues/198#issuecomment-1488996737",
" New-Item $fontInstallDir -ItemType Directory -ErrorAction SilentlyContinue | Out-Null",
" $accessControlList = Get-Acl $fontInstallDir",
" $allApplicationPackagesAccessRule = New-Object System.Security.AccessControl.FileSystemAccessRule([System.Security.Principal.SecurityIdentifier]::new(\"S-1-15-2-1\"), \"ReadAndExecute\", \"ContainerInherit,ObjectInherit\", \"None\", \"Allow\")",
" $allRestrictedApplicationPackagesAccessRule = New-Object System.Security.AccessControl.FileSystemAccessRule([System.Security.Principal.SecurityIdentifier]::new(\"S-1-15-2-2\"), \"ReadAndExecute\", \"ContainerInherit,ObjectInherit\", \"None\", \"Allow\")",
" $accessControlList.SetAccessRule($allApplicationPackagesAccessRule)",
" $accessControlList.SetAccessRule($allRestrictedApplicationPackagesAccessRule)",
" Set-Acl -AclObject $accessControlList $fontInstallDir",
"}",
"$registryRoot = if ($global) { \"HKLM\" } else { \"HKCU\" }",
"$registryKey = \"${registryRoot}:\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Fonts\"",
"Get-ChildItem $dir -Filter '*NerdFontMono-*' | ForEach-Object {",
" $value = if ($global) { $_.Name } else { \"$fontInstallDir\\$($_.Name)\" }",
" New-ItemProperty -Path $registryKey -Name $_.Name.Replace($_.Extension, ' (TrueType)') -Value $value -Force | Out-Null",
" Copy-Item $_.FullName -Destination $fontInstallDir",
"}"
]
},
"pre_uninstall": [
"$fontInstallDir = if ($global) { \"$env:windir\\Fonts\" } else { \"$env:LOCALAPPDATA\\Microsoft\\Windows\\Fonts\" }",
"Get-ChildItem $dir -Filter '*NerdFontMono-*' | ForEach-Object {",
" Get-ChildItem $fontInstallDir -Filter $_.Name | ForEach-Object {",
" try {",
" Rename-Item $_.FullName $_.FullName -ErrorVariable LockError -ErrorAction Stop",
" } catch {",
" Write-Host \"\"",
" Write-Host \" Error \" -Background DarkRed -Foreground White -NoNewline",
" Write-Host \"\"",
" Write-Host \" Cannot uninstall '$app' font.\" -Foreground DarkRed",
" Write-Host \"\"",
" Write-Host \" Reason \" -Background DarkCyan -Foreground White -NoNewline",
" Write-Host \"\"",
" Write-Host \" The '$app' font is currently being used by another application,\" -Foreground DarkCyan",
" Write-Host \" so it cannot be deleted.\" -Foreground DarkCyan",
" Write-Host \"\"",
" Write-Host \" Suggestion \" -Background Magenta -Foreground White -NoNewline",
" Write-Host \"\"",
" Write-Host \" Close all applications that are using '$app' font (e.g. vscode),\" -Foreground Magenta",
" Write-Host \" and then try again.\" -Foreground Magenta",
" Write-Host \"\"",
" exit 1",
" }",
" }",
"}"
],
"uninstaller": {
"script": [
"$fontInstallDir = if ($global) { \"$env:windir\\Fonts\" } else { \"$env:LOCALAPPDATA\\Microsoft\\Windows\\Fonts\" }",
"$registryRoot = if ($global) { \"HKLM\" } else { \"HKCU\" }",
"$registryKey = \"${registryRoot}:\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Fonts\"",
"Get-ChildItem $dir -Filter '*NerdFontMono-*' | ForEach-Object {",
" Remove-ItemProperty -Path $registryKey -Name $_.Name.Replace($_.Extension, ' (TrueType)') -Force -ErrorAction SilentlyContinue",
" Remove-Item \"$fontInstallDir\\$($_.Name)\" -Force -ErrorAction SilentlyContinue",
"}",
"if ($cmd -eq \"uninstall\") {",
" Write-Host \"The '$app' Font family has been uninstalled and will not be present after restarting your computer.\" -Foreground Magenta",
"}"
]
},
"checkver": "github",
"autoupdate": {
"url": "https://github.com/ryanoasis/nerd-fonts/releases/download/v$version/CommitMono.zip"
}
}
92 changes: 92 additions & 0 deletions bucket/CommitMono-NF-Propo.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
{
"version": "3.1.0",
"description": "Nerd Fonts patched 'CommitMono' Font family. (Proportional version, for GUI usecases)",
"homepage": "https://github.com/ryanoasis/nerd-fonts",
"license": "MIT",
"url": "https://github.com/ryanoasis/nerd-fonts/releases/download/v3.1.0/CommitMono.zip",
"hash": "1ba8a0fa707298856c80ee2b8b9ac1dc1dd3dbfdc9c4a7d8ebfbc5f0b650df89",
"installer": {
"script": [
"$currentBuildNumber = [int] (Get-ItemProperty \"HKLM:\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\").CurrentBuildNumber",
"$windows10Version1809BuildNumber = 17763",
"$isPerUserFontInstallationSupported = $currentBuildNumber -ge $windows10Version1809BuildNumber",
"if (!$isPerUserFontInstallationSupported -and !$global) {",
" scoop uninstall $app",
" Write-Host \"\"",
" Write-Host \"For Windows version before Windows 10 Version 1809 (OS Build 17763),\" -Foreground DarkRed",
" Write-Host \"Font can only be installed for all users.\" -Foreground DarkRed",
" Write-Host \"\"",
" Write-Host \"Please use following commands to install '$app' Font for all users.\" -Foreground DarkRed",
" Write-Host \"\"",
" Write-Host \" scoop install sudo\"",
" Write-Host \" sudo scoop install -g $app\"",
" Write-Host \"\"",
" exit 1",
"}",
"$fontInstallDir = if ($global) { \"$env:windir\\Fonts\" } else { \"$env:LOCALAPPDATA\\Microsoft\\Windows\\Fonts\" }",
"if (-not $global) {",
" # Ensure user font install directory exists and has correct permission settings",
" # See https://github.com/matthewjberger/scoop-nerd-fonts/issues/198#issuecomment-1488996737",
" New-Item $fontInstallDir -ItemType Directory -ErrorAction SilentlyContinue | Out-Null",
" $accessControlList = Get-Acl $fontInstallDir",
" $allApplicationPackagesAccessRule = New-Object System.Security.AccessControl.FileSystemAccessRule([System.Security.Principal.SecurityIdentifier]::new(\"S-1-15-2-1\"), \"ReadAndExecute\", \"ContainerInherit,ObjectInherit\", \"None\", \"Allow\")",
" $allRestrictedApplicationPackagesAccessRule = New-Object System.Security.AccessControl.FileSystemAccessRule([System.Security.Principal.SecurityIdentifier]::new(\"S-1-15-2-2\"), \"ReadAndExecute\", \"ContainerInherit,ObjectInherit\", \"None\", \"Allow\")",
" $accessControlList.SetAccessRule($allApplicationPackagesAccessRule)",
" $accessControlList.SetAccessRule($allRestrictedApplicationPackagesAccessRule)",
" Set-Acl -AclObject $accessControlList $fontInstallDir",
"}",
"$registryRoot = if ($global) { \"HKLM\" } else { \"HKCU\" }",
"$registryKey = \"${registryRoot}:\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Fonts\"",
"Get-ChildItem $dir -Filter '*NerdFontPropo-*' | ForEach-Object {",
" $value = if ($global) { $_.Name } else { \"$fontInstallDir\\$($_.Name)\" }",
" New-ItemProperty -Path $registryKey -Name $_.Name.Replace($_.Extension, ' (TrueType)') -Value $value -Force | Out-Null",
" Copy-Item $_.FullName -Destination $fontInstallDir",
"}"
]
},
"pre_uninstall": [
"$fontInstallDir = if ($global) { \"$env:windir\\Fonts\" } else { \"$env:LOCALAPPDATA\\Microsoft\\Windows\\Fonts\" }",
"Get-ChildItem $dir -Filter '*NerdFontPropo-*' | ForEach-Object {",
" Get-ChildItem $fontInstallDir -Filter $_.Name | ForEach-Object {",
" try {",
" Rename-Item $_.FullName $_.FullName -ErrorVariable LockError -ErrorAction Stop",
" } catch {",
" Write-Host \"\"",
" Write-Host \" Error \" -Background DarkRed -Foreground White -NoNewline",
" Write-Host \"\"",
" Write-Host \" Cannot uninstall '$app' font.\" -Foreground DarkRed",
" Write-Host \"\"",
" Write-Host \" Reason \" -Background DarkCyan -Foreground White -NoNewline",
" Write-Host \"\"",
" Write-Host \" The '$app' font is currently being used by another application,\" -Foreground DarkCyan",
" Write-Host \" so it cannot be deleted.\" -Foreground DarkCyan",
" Write-Host \"\"",
" Write-Host \" Suggestion \" -Background Magenta -Foreground White -NoNewline",
" Write-Host \"\"",
" Write-Host \" Close all applications that are using '$app' font (e.g. vscode),\" -Foreground Magenta",
" Write-Host \" and then try again.\" -Foreground Magenta",
" Write-Host \"\"",
" exit 1",
" }",
" }",
"}"
],
"uninstaller": {
"script": [
"$fontInstallDir = if ($global) { \"$env:windir\\Fonts\" } else { \"$env:LOCALAPPDATA\\Microsoft\\Windows\\Fonts\" }",
"$registryRoot = if ($global) { \"HKLM\" } else { \"HKCU\" }",
"$registryKey = \"${registryRoot}:\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Fonts\"",
"Get-ChildItem $dir -Filter '*NerdFontPropo-*' | ForEach-Object {",
" Remove-ItemProperty -Path $registryKey -Name $_.Name.Replace($_.Extension, ' (TrueType)') -Force -ErrorAction SilentlyContinue",
" Remove-Item \"$fontInstallDir\\$($_.Name)\" -Force -ErrorAction SilentlyContinue",
"}",
"if ($cmd -eq \"uninstall\") {",
" Write-Host \"The '$app' Font family has been uninstalled and will not be present after restarting your computer.\" -Foreground Magenta",
"}"
]
},
"checkver": "github",
"autoupdate": {
"url": "https://github.com/ryanoasis/nerd-fonts/releases/download/v$version/CommitMono.zip"
}
}
92 changes: 92 additions & 0 deletions bucket/CommitMono-NF.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
{
"version": "3.1.0",
"description": "Nerd Fonts patched 'CommitMono' Font family. (Normal version, Nerd Fonts Symbol/Icon could be 1 or 2 cell wide)",
"homepage": "https://github.com/ryanoasis/nerd-fonts",
"license": "MIT",
"url": "https://github.com/ryanoasis/nerd-fonts/releases/download/v3.1.0/CommitMono.zip",
"hash": "1ba8a0fa707298856c80ee2b8b9ac1dc1dd3dbfdc9c4a7d8ebfbc5f0b650df89",
"installer": {
"script": [
"$currentBuildNumber = [int] (Get-ItemProperty \"HKLM:\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\").CurrentBuildNumber",
"$windows10Version1809BuildNumber = 17763",
"$isPerUserFontInstallationSupported = $currentBuildNumber -ge $windows10Version1809BuildNumber",
"if (!$isPerUserFontInstallationSupported -and !$global) {",
" scoop uninstall $app",
" Write-Host \"\"",
" Write-Host \"For Windows version before Windows 10 Version 1809 (OS Build 17763),\" -Foreground DarkRed",
" Write-Host \"Font can only be installed for all users.\" -Foreground DarkRed",
" Write-Host \"\"",
" Write-Host \"Please use following commands to install '$app' Font for all users.\" -Foreground DarkRed",
" Write-Host \"\"",
" Write-Host \" scoop install sudo\"",
" Write-Host \" sudo scoop install -g $app\"",
" Write-Host \"\"",
" exit 1",
"}",
"$fontInstallDir = if ($global) { \"$env:windir\\Fonts\" } else { \"$env:LOCALAPPDATA\\Microsoft\\Windows\\Fonts\" }",
"if (-not $global) {",
" # Ensure user font install directory exists and has correct permission settings",
" # See https://github.com/matthewjberger/scoop-nerd-fonts/issues/198#issuecomment-1488996737",
" New-Item $fontInstallDir -ItemType Directory -ErrorAction SilentlyContinue | Out-Null",
" $accessControlList = Get-Acl $fontInstallDir",
" $allApplicationPackagesAccessRule = New-Object System.Security.AccessControl.FileSystemAccessRule([System.Security.Principal.SecurityIdentifier]::new(\"S-1-15-2-1\"), \"ReadAndExecute\", \"ContainerInherit,ObjectInherit\", \"None\", \"Allow\")",
" $allRestrictedApplicationPackagesAccessRule = New-Object System.Security.AccessControl.FileSystemAccessRule([System.Security.Principal.SecurityIdentifier]::new(\"S-1-15-2-2\"), \"ReadAndExecute\", \"ContainerInherit,ObjectInherit\", \"None\", \"Allow\")",
" $accessControlList.SetAccessRule($allApplicationPackagesAccessRule)",
" $accessControlList.SetAccessRule($allRestrictedApplicationPackagesAccessRule)",
" Set-Acl -AclObject $accessControlList $fontInstallDir",
"}",
"$registryRoot = if ($global) { \"HKLM\" } else { \"HKCU\" }",
"$registryKey = \"${registryRoot}:\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Fonts\"",
"Get-ChildItem $dir -Filter '*NerdFont-*' | ForEach-Object {",
" $value = if ($global) { $_.Name } else { \"$fontInstallDir\\$($_.Name)\" }",
" New-ItemProperty -Path $registryKey -Name $_.Name.Replace($_.Extension, ' (TrueType)') -Value $value -Force | Out-Null",
" Copy-Item $_.FullName -Destination $fontInstallDir",
"}"
]
},
"pre_uninstall": [
"$fontInstallDir = if ($global) { \"$env:windir\\Fonts\" } else { \"$env:LOCALAPPDATA\\Microsoft\\Windows\\Fonts\" }",
"Get-ChildItem $dir -Filter '*NerdFont-*' | ForEach-Object {",
" Get-ChildItem $fontInstallDir -Filter $_.Name | ForEach-Object {",
" try {",
" Rename-Item $_.FullName $_.FullName -ErrorVariable LockError -ErrorAction Stop",
" } catch {",
" Write-Host \"\"",
" Write-Host \" Error \" -Background DarkRed -Foreground White -NoNewline",
" Write-Host \"\"",
" Write-Host \" Cannot uninstall '$app' font.\" -Foreground DarkRed",
" Write-Host \"\"",
" Write-Host \" Reason \" -Background DarkCyan -Foreground White -NoNewline",
" Write-Host \"\"",
" Write-Host \" The '$app' font is currently being used by another application,\" -Foreground DarkCyan",
" Write-Host \" so it cannot be deleted.\" -Foreground DarkCyan",
" Write-Host \"\"",
" Write-Host \" Suggestion \" -Background Magenta -Foreground White -NoNewline",
" Write-Host \"\"",
" Write-Host \" Close all applications that are using '$app' font (e.g. vscode),\" -Foreground Magenta",
" Write-Host \" and then try again.\" -Foreground Magenta",
" Write-Host \"\"",
" exit 1",
" }",
" }",
"}"
],
"uninstaller": {
"script": [
"$fontInstallDir = if ($global) { \"$env:windir\\Fonts\" } else { \"$env:LOCALAPPDATA\\Microsoft\\Windows\\Fonts\" }",
"$registryRoot = if ($global) { \"HKLM\" } else { \"HKCU\" }",
"$registryKey = \"${registryRoot}:\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Fonts\"",
"Get-ChildItem $dir -Filter '*NerdFont-*' | ForEach-Object {",
" Remove-ItemProperty -Path $registryKey -Name $_.Name.Replace($_.Extension, ' (TrueType)') -Force -ErrorAction SilentlyContinue",
" Remove-Item \"$fontInstallDir\\$($_.Name)\" -Force -ErrorAction SilentlyContinue",
"}",
"if ($cmd -eq \"uninstall\") {",
" Write-Host \"The '$app' Font family has been uninstalled and will not be present after restarting your computer.\" -Foreground Magenta",
"}"
]
},
"checkver": "github",
"autoupdate": {
"url": "https://github.com/ryanoasis/nerd-fonts/releases/download/v$version/CommitMono.zip"
}
}