mirror of
https://github.com/fleschutz/PowerShell.git
synced 2025-01-23 06:08:36 +01:00
Improve the scripts
This commit is contained in:
parent
61900ec1d9
commit
6ee8ea905f
@ -11,6 +11,7 @@ URL,Directory
|
||||
"https://github.com/llvm/llvm-project", "llvm"
|
||||
"https://github.com/smartmontools/smartmontools", "smartmontools"
|
||||
"https://github.com/synesthesiam/voice2json", "voice2json"
|
||||
"https://github.com/tensorflow/tensorflow", "tensorflow"
|
||||
"https://github.com/TinyCC/tinycc", "tinycc"
|
||||
"https://github.com/opencv/opencv", "opencv"
|
||||
"https://github.com/openzfs/zfs", "zfs"
|
||||
|
|
@ -1,8 +1,6 @@
|
||||
Script,Description
|
||||
add-firewall-rules.ps1, adds firewall rules to the given executables (needs admin rights)
|
||||
add-memo.ps1, adds the given memo text to $HOME/Memos.csv
|
||||
build-repo.ps1, builds the current/given Git repository
|
||||
build-repos.ps1, builds all Git repositories under the current/given directory
|
||||
cd-desktop.ps1, go to the user's desktop folder
|
||||
cd-docs.ps1, go to the user's documents folder
|
||||
cd-downloads.ps1, go to the user's downloads folder
|
||||
@ -132,6 +130,8 @@ locate-ipaddress.ps1, prints the geographic location of the given IP address
|
||||
locate-zip-code.ps1, prints the geographic location of the given zip-code
|
||||
MD5.ps1, prints the MD5 checksum of the given file
|
||||
make-install.ps1, installs built executables and libs to the installation directory
|
||||
make-repo.ps1, builds the current/given Git repository
|
||||
make-repos.ps1, builds all Git repositories under the current/given directory
|
||||
moon.ps1, prints the current moon phase
|
||||
mute-audio.ps1, mutes audio
|
||||
next-joke.ps1], gets the next random Juck Norris joke
|
||||
|
|
@ -139,8 +139,6 @@ Mega Collection of PowerShell Scripts
|
||||
|
||||
📝 PowerShell Scripts for Git
|
||||
------------------------------
|
||||
* [build-repo.ps1](Scripts/build-repo.ps1) - builds the current/given Git repository
|
||||
* [build-repos.ps1](Scripts/build-repos.ps1) - builds all Git repositories under the current/given directory
|
||||
* [cherry-picker.ps1](Scripts/cherry-picker.ps1) - cherry-picks a Git commit into multiple branches
|
||||
* [clean-repo.ps1](Scripts/clean-repo.ps1) - cleans the current/given Git repository from untracked files (including submodules)
|
||||
* [clean-repos.ps1](Scripts/clean-repos.ps1) - cleans all Git repositories under the current/given directory from untracked files (including submodules)
|
||||
@ -155,6 +153,8 @@ Mega Collection of PowerShell Scripts
|
||||
* [list-latest-tag.ps1](Scripts/list-latest-tag.ps1) - lists the latest tag on the current branch in a Git repository
|
||||
* [list-submodules.ps1](Scripts/list-submodules.ps1) - lists the submodules of the current/given Git repository
|
||||
* [list-tags.ps1](Scripts/list-tags.ps1) - lists all tags in the current/given Git repository
|
||||
* [make-repo.ps1](Scripts/make-repo.ps1) - builds the current/given Git repository
|
||||
* [make-repos.ps1](Scripts/make-repos.ps1) - builds all Git repositories under the current/given directory
|
||||
* [pull-repo.ps1](Scripts/pull-repo.ps1) - pulls updates for the current/given Git repository (including submodules)
|
||||
* [pull-repos.ps1](Scripts/pull-repos.ps1) - pulls updates for all Git repositories under the current/given directory (including submodules)
|
||||
* [switch-branch.ps1](Scripts/switch-branch.ps1) - switches the branch in the current/given Git repository (including submodules)
|
||||
|
@ -22,10 +22,10 @@ try {
|
||||
$URL = $Row.URL
|
||||
$DirName = $Row.Directory
|
||||
if (test-path "$ParentDir/$DirName" -pathType container) {
|
||||
"Skipping 📂$DirName because it exists already ..."
|
||||
"Skipping 📂$DirName (exists already)..."
|
||||
continue
|
||||
}
|
||||
"⏳ Cloning $URL to 📂$DirName ..."
|
||||
"⏳ Cloning $URL to 📂$($DirName)..."
|
||||
& git clone --recurse-submodules "$URL" "$ParentDir/$DirName"
|
||||
if ($lastExitCode -ne "0") { throw "'git clone $URL' failed" }
|
||||
$Count++
|
||||
|
@ -1,6 +1,6 @@
|
||||
<#
|
||||
.SYNTAX build-repo.ps1 [<repo-dir>]
|
||||
.DESCRIPTION builds a Git repository (supporting cmake,configure,autogen,Imakefile,Makefile)
|
||||
.SYNTAX make-repo.ps1 [<repo-dir>]
|
||||
.DESCRIPTION builds a Git repository supporting cmake,configure,autogen,Imakefile,Makefile
|
||||
.LINK https://github.com/fleschutz/PowerShell
|
||||
.NOTES Author: Markus Fleschutz / License: CC0
|
||||
#>
|
@ -1,5 +1,5 @@
|
||||
<#
|
||||
.SYNTAX build-repos.ps1 [<parent-dir>]
|
||||
.SYNTAX make-repos.ps1 [<parent-dir>]
|
||||
.DESCRIPTION builds all Git repositories under the current/given directory
|
||||
.LINK https://github.com/fleschutz/PowerShell
|
||||
.NOTES Author: Markus Fleschutz / License: CC0
|
||||
@ -17,7 +17,7 @@ try {
|
||||
"Building $($Folders.Count) Git repositories at 📂$ParentDirName..."
|
||||
|
||||
foreach ($Folder in $Folders) {
|
||||
& "$PSScriptRoot/build-repo.ps1" "$Folder"
|
||||
& "$PSScriptRoot/make-repo.ps1" "$Folder"
|
||||
}
|
||||
|
||||
[int]$Elapsed = $StopWatch.Elapsed.TotalSeconds
|
Loading…
Reference in New Issue
Block a user