Skip to content
This repository has been archived by the owner on Feb 1, 2025. It is now read-only.

Developing in PSCAT

Nicholas Gautier edited this page Jan 27, 2025 · 4 revisions

Introduction

The source files for the PowerShell Compact-Archive Tool are completely open source and fully transparent, meaning anyone can access the entire project and make changes. One of the greatest benefits of using PowerShell is that anyone can open the scripts in a simple text editor and modify them. If you want to make changes to PSCAT, update it, add useful features, or anything else, you have the power to do so — right now! Fork this repository and get started!

Resources Required

This is the environment that I am using, as of 19.Jan.2025, and I know it works. Feel free to experiment and add your own flavoring.

  1. Microsoft Windows 11 23H2 Operating System
  2. PowerShell Core v7.4.6
  3. Inno Setup v6.3.3
  4. Your preferred Git-SCM Front-End Client
    1. Ideas for Front-End Clients:
      1. GitHub Desktop for Windows Environment
      2. GitKraken on Linux
  5. Visual Studio Code
    1. PowerShell from Microsoft v2024.4.0
    2. Inno Setup from Chouzz v1.9.3

Known to NOT Work

  1. Windows PowerShell v5.1
  2. Windows PowerShell ISE

The PowerShell Compact-Archive Tool is Object-Oriented and uses PowerShell Core's capabilities. Windows PowerShell, however, contains very limited functionalities with classes and lacks features that are needed for PSCAT.

Filesystem Structure

This section will only focus on the high-level view of the folder hierarchy, anything specific you are looking for - you'll just have to dive into the code.

  • Compile
    • Contains a Make script that can allow you to compile PSCAT.
  • Documents
    • Contains developmental and general documents related to the PSCAT project.
  • Github Services
    • Contains assets that will be used for the Wiki or other resources provided by GitHub.
  • Installer
    • Contains the Inno Setup script files required to generate an installer.
  • Scripts
    • The PowerShell Compact-Archive Tool scripts.

Compiling the PowerShell Compact-Archive Tool

When you make a change to the PSCAT script(s), you can use the Make.ps1 script—located in Compile/Make.ps1 in order to generate a new build of the PSCAT program. To test the build, start a new PowerShell Core instance, then navigate to and execute the Scripts/Launcher/Launcher.ps1 script. This will perform the necessary imports for the Windows graphical components into the PowerShell Core's environment. Afterward, you can execute the newly compiled PSCAT build by running Compile/PSCAT.ps1.

NOTE: It is strongly recommended not to use the Launcher.ps1 while debugging or developing PSCAT. The Launcher.ps1 will abruptly clear the terminal buffer to show a very generic error message when the entire program crashes.

See Also