mirror of
https://github.com/fleschutz/PowerShell.git
synced 2025-03-25 13:36:39 +01:00
Add go-desktop.ps1 and go-dropbox.ps1
This commit is contained in:
parent
f83042c654
commit
42512ee54a
@ -51,7 +51,9 @@ encrypt-file.ps1, encrypts the given file
|
||||
fetch-repo.ps1, fetches updates for the current/given Git repository (including submodules)
|
||||
fetch-repos.ps1, fetches updates for all Git repositories under the current/given directory (including submodules)
|
||||
generate-qrcode.ps1, generates a QR code
|
||||
go-desktop.ps1, go to the user's desktop folder
|
||||
go-downloads.ps1, go to the user's downloads folder
|
||||
go-dropbox.ps1, go to the user's dropbox folder
|
||||
go-home.ps1, go to the user's home folder
|
||||
go-music.ps1, go to the user's music folder
|
||||
go-repos.ps1, go to the user's Git repositories folder
|
||||
|
|
@ -1,7 +1,7 @@
|
||||
Mega Collection of PowerShell Scripts
|
||||
=====================================
|
||||
|
||||
**This repository provides more than 180 useful and cross-platform PowerShell scripts in the subfolder [Scripts/](Scripts/) - to be used by command-line interface (CLI), for remote control (e.g. via SSH), by context menu, by voice control, by automation software like Jenkins, automatically as daily tasks, or simply to learn PowerShell. See the [PowerShell FAQ page](Misc/FAQ.md) if you need help or have any questions.**
|
||||
**This repository provides more than 190 useful and cross-platform PowerShell scripts in the subfolder [Scripts/](Scripts/) - to be used by command-line interface (CLI), for remote control (e.g. via SSH), by context menu, by voice control, by automation software like Jenkins, automatically as daily tasks, or simply to learn PowerShell. See the [PowerShell FAQ page](Misc/FAQ.md) if you need help or have any questions.**
|
||||
|
||||
🔊 PowerShell Scripts for Audio & Voice
|
||||
----------------------------------------
|
||||
@ -95,7 +95,9 @@ Mega Collection of PowerShell Scripts
|
||||
* [download-file.ps1](Scripts/download-file.ps1) - downloads a file from the given URL
|
||||
* [edit.ps1](Scripts/edit.ps1) - edits the given file with the built-in text editor
|
||||
* [encrypt-file.ps1](Scripts/encrypt-file.ps1) - encrypts the given file
|
||||
* [go-desktop.ps1](Scripts/go-desktop.ps1) - go to the user's desktop folder
|
||||
* [go-downloads.ps1](Scripts/go-downloads.ps1) - go to the user's downloads folder
|
||||
* [go-dropbox.ps1](Scripts/go-dropbox.ps1) - go to the user's dropbox folder
|
||||
* [go-home.ps1](Scripts/go-home.ps1) - go to the user's home folder
|
||||
* [go-music.ps1](Scripts/go-music.ps1) - go to the user's music folder
|
||||
* [go-repos.ps1](Scripts/go-repos.ps1) - go to the user's Git repositories folder
|
||||
|
17
Scripts/go-desktop.ps1
Executable file
17
Scripts/go-desktop.ps1
Executable file
@ -0,0 +1,17 @@
|
||||
#!/usr/bin/pwsh
|
||||
<#
|
||||
.SYNTAX go-desktop.ps1
|
||||
.DESCRIPTION go to the user's desktop folder
|
||||
.LINK https://github.com/fleschutz/PowerShell
|
||||
.NOTES Author: Markus Fleschutz / License: CC0
|
||||
#>
|
||||
|
||||
try {
|
||||
$TargetDir = resolve-path "$HOME/Desktop/"
|
||||
set-location "$TargetDir"
|
||||
"📂$TargetDir"
|
||||
exit 0
|
||||
} catch {
|
||||
write-error "ERROR: line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||
exit 1
|
||||
}
|
@ -9,7 +9,7 @@
|
||||
try {
|
||||
$TargetDir = resolve-path "$HOME/Downloads/"
|
||||
set-location "$TargetDir"
|
||||
" 📂$TargetDir"
|
||||
"📂$TargetDir"
|
||||
exit 0
|
||||
} catch {
|
||||
write-error "ERROR: line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||
|
17
Scripts/go-dropbox.ps1
Executable file
17
Scripts/go-dropbox.ps1
Executable file
@ -0,0 +1,17 @@
|
||||
#!/usr/bin/pwsh
|
||||
<#
|
||||
.SYNTAX go-dropbox.ps1
|
||||
.DESCRIPTION go to the user's Dropbox folder
|
||||
.LINK https://github.com/fleschutz/PowerShell
|
||||
.NOTES Author: Markus Fleschutz / License: CC0
|
||||
#>
|
||||
|
||||
try {
|
||||
$TargetDir = resolve-path "$HOME/Dropbox/"
|
||||
set-location "$TargetDir"
|
||||
"📂$TargetDir"
|
||||
exit 0
|
||||
} catch {
|
||||
write-error "ERROR: line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||
exit 1
|
||||
}
|
@ -9,7 +9,7 @@
|
||||
try {
|
||||
$TargetDir = resolve-path "$HOME/"
|
||||
set-location "$TargetDir"
|
||||
" 📂$TargetDir"
|
||||
"📂$TargetDir"
|
||||
exit 0
|
||||
} catch {
|
||||
write-error "ERROR: line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||
|
@ -9,7 +9,7 @@
|
||||
try {
|
||||
$TargetDir = resolve-path "$HOME/Music/"
|
||||
set-location "$TargetDir"
|
||||
" 📂$TargetDir"
|
||||
"📂$TargetDir"
|
||||
exit 0
|
||||
} catch {
|
||||
write-error "ERROR: line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||
|
@ -9,7 +9,7 @@
|
||||
try {
|
||||
$TargetDir = resolve-path "$HOME/Repos/"
|
||||
set-location "$TargetDir"
|
||||
" 📂$TargetDir"
|
||||
"📂$TargetDir"
|
||||
exit 0
|
||||
} catch {
|
||||
write-error "ERROR: line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||
|
@ -13,7 +13,7 @@ try {
|
||||
$TargetDir = resolve-path "C:/"
|
||||
}
|
||||
set-location "$TargetDir"
|
||||
" 📂$TargetDir"
|
||||
"📂$TargetDir"
|
||||
exit 0
|
||||
} catch {
|
||||
write-error "ERROR: line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||
|
@ -9,7 +9,7 @@
|
||||
try {
|
||||
$TargetDir = resolve-path "$PSScriptRoot/"
|
||||
set-location "$TargetDir"
|
||||
" 📂$TargetDir"
|
||||
"📂$TargetDir"
|
||||
exit 0
|
||||
} catch {
|
||||
write-error "ERROR: line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||
|
Loading…
Reference in New Issue
Block a user