https://github.com/uqueno/ykn-powershell-scripts
Curated PowerShell scripts for SSH automation, VS Code environment fixes, and MobaXterm integration—foundation for the future Ykn.SSH.Tools module.
https://github.com/uqueno/ykn-powershell-scripts
automation devops documentation mobaxterm powershell scripts ssh tooling vscode
Last synced: 5 months ago
JSON representation
Curated PowerShell scripts for SSH automation, VS Code environment fixes, and MobaXterm integration—foundation for the future Ykn.SSH.Tools module.
- Host: GitHub
- URL: https://github.com/uqueno/ykn-powershell-scripts
- Owner: uqueno
- License: other
- Created: 2025-10-01T23:45:55.000Z (6 months ago)
- Default Branch: main
- Last Pushed: 2025-10-03T23:43:06.000Z (6 months ago)
- Last Synced: 2025-10-04T01:20:57.337Z (6 months ago)
- Topics: automation, devops, documentation, mobaxterm, powershell, scripts, ssh, tooling, vscode
- Language: PowerShell
- Homepage: https://github.com/uqueno/ykn-powershell-scripts
- Size: 108 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ykn-powershell-scripts
Collection of PowerShell scripts for SSH automation, VS Code troubleshooting, environment setup, and general workflow acceleration.
> NOTE: Local folder was `Scripts`. Repository name uses corrected spelling: `ykn-powershell-scripts`.
## 📦 Topics / Tags
Automation, PowerShell, SSH, DevOps, VSCode, Remote-SSH, Tooling, Windows, Productivity
## 📁 Contents
| File | Purpose |
|------|---------|
| `Generate-SSHKey.ps1` | Full-featured SSH key generator with naming convention & permissions fix |
| `Quick-SSHKey.ps1` | Minimal wrapper for fast key generation |
| `SSH-Connection-Tester.ps1` | Interactive SSH host tester parsing `~/.ssh/config` |
| `Advanced-SSH-Connection-Tester.ps1` | (Planned/Experimental) Extended diagnostics version |
| `Quick-SSH-Test.ps1` | Fast single-host connectivity check |
| `VSCode-SSH-Test-*.ps1` | Targeted VS Code SSH validation scripts |
| `Fix-VSCode-SSH-Navigator*.ps1` | Workarounds for Remote-SSH navigator errors |
| `Set-VSCode-PowerShell-Default.ps1` | Set PowerShell as default terminal in VS Code |
| `Simple-PowerShell-Default.ps1` | Lightweight variant for terminal default |
| `SSH-Connection-Tester-Documentation.md` | Full technical reference for tester script |
| `MobaXterm-*.md` | Guides for MobaXterm integration attempts |
| `Generate-SSHKey-README.md` | Detailed SSH key generation documentation |
| `*.md` | Remaining documentation, troubleshooting guides, setup notes |
## 🔧 Prerequisites
- Windows 10/11 with PowerShell 5.1+ (PowerShell 7 supported for most scripts)
- OpenSSH client installed (Windows optional feature)
- VS Code (for related Remote-SSH scripts)
## 🚀 Quick Start
```powershell
# Clone (after you push this repository)
git clone https://github.com//ykn-powershell-scripts.git
Set-Location ykn-powershell-scripts
# List scripts
Get-ChildItem *.ps1
# Run key generator (example)
./Generate-SSHKey.ps1 -User coolify -Host vmi2747748 -Address 77.237.241.154 -Client windows
```
## 🧪 Testing Connectivity
```powershell
# Parse ~/.ssh/config and test all hosts
./SSH-Connection-Tester.ps1
# Quick single test
./Quick-SSH-Test.ps1 -Host coolify-contabo-n8n
```
## 🗂 Suggested Directory Layout
Keep scripts directly in repo root (as currently) for simplicity. Optional future structure:
```text
/scripts
/docs
/modules
/tests
```
## 🧩 Toward a Module (Overview)
A future `Ykn.SSH.Tools` PowerShell module could encapsulate reusable functions:
| Proposed Module Path | Purpose |
|----------------------|---------|
| `modules/Ykn.SSH.Tools/Ykn.SSH.Tools.psd1` | Module manifest (metadata, exported functions) |
| `modules/Ykn.SSH.Tools/Ykn.SSH.Tools.psm1` | Implementation importing individual function files |
| `modules/Ykn.SSH.Tools/Public/*.ps1` | Public functions (e.g., `New-YknSshKey`, `Test-YknSshHost`) |
| `modules/Ykn.SSH.Tools/Private/*.ps1` | Internal helpers (parsing, formatting) |
| `modules/Ykn.SSH.Tools/Format/*.ps1xml` | (Optional) Custom object views |
| `tests/*.Tests.ps1` | Pester tests for public functions |
Benefits:
- Import once: `Import-Module ./modules/Ykn.SSH.Tools`
- Clear public API & semantic versioning
- Easier packaging (PowerShell Gallery option)
- Centralized error handling & logging
See `MODULE-GUIDE.md` (added) for detailed steps.
## ✅ Roadmap Ideas
- Add Pester tests for key generator and parser functions
- Package core functions into a module (`Ykn.SSH.Tools`)
- Add parallel host testing + performance metrics
- Continuous integration (GitHub Actions) for linting (PSScriptAnalyzer)
- Optional JSON output mode for automation
- Add module manifest & convert scripts into functions
- Provide signed script examples (code signing)
## 🧹 Code Quality
Run basic linting (if PowerShell 7 installed):
```powershell
pwsh -Command "Invoke-ScriptAnalyzer -Path . -Recurse"
```
## 📄 License
MIT (see `LICENSE`)
## 🙋 Support / Notes
Author: Yukio Ueno
Issues and PRs welcome. These scripts originated from iterative troubleshooting of SSH + VS Code Remote-SSH flows and are intentionally pragmatic.
---
Happy scripting! 🔧