AppRefiner is a powerful companion application designed to enhance PeopleSoft's Application Designer with modern development features. It adds code folding, linting, syntax highlighting, and refactoring tools that are not available in the native Application Designer environment.
Rather than replacing Application Designer, AppRefiner seamlessly integrates with it to provide additional functionality while you work with PeopleCode. The most efficient way to access AppRefiner's features is through the Command Palette (Ctrl+Shift+P), which works similarly to VS Code and provides quick access to all functionality.
- Code Folding: Collapse and expand code blocks for better organization
- SQL Formatting: Improved edit-time formatting for SQL objects
- Annotations: In-line visual feedback directly in the editor
- Dark Mode: Support for dark mode in code editors
- Linting: Automatically detect issues like empty catch blocks, nested if-else statements, SQL wildcard usage, and more
- SQL Validation: Validate SQL parameter binding, detect potential SQL injection risks, and validate SQL definition references
- Style Analysis: Highlight style issues such as meaningless variable names, properties used as variables, and unused imports
- Variable Renaming: Easily rename local variables, parameters, and more
- Import Optimization: Clean up and organize import statements
- FlowerBox Headers: Add proper documentation headers to your code
- Command Palette: Quick access to all features (Ctrl+Shift+P)
- Templates: Pre-built code templates for common patterns
- Database Integration: Connect to Oracle PeopleSoft databases to enhance linting capabilities
- Global Hotkeys: Keyboard shortcuts that work directly inside Application Designer
What's New Since the Podcast
A lot has happened since the podcast episode! Here are some highlights:
- Core Features & Enhancements:
- Inline Annotations & Quick Fixes: Introduced inline annotations (squiggles, highlights, text color) for stylers, replacing the old Linter tab/grid. Many stylers now offer "Quick Fixes" directly from the annotation tooltip to automatically resolve the issue.
- Refactoring Improvements:
- Refactors can now trigger follow-up refactors (e.g., implementing a base class automatically resolves imports).
- Templates: Added support for templates that insert into existing code instead of replacing the content.
- Database Integration: Improved the database connection experience, especially with saved passwords.
- Performance: AppRefiner no longer relies on a scanning timer, instead it now detects typing pauses and processes stylers/tooltips at that point for better performance.
- New Functionality:
- Added App Class Path autocompletion (requires DB connection).
- Implemented a
create()shortcut which automatically expands to the the app class name. - Added a "Go To" command which gives a high level structure of the Application Class and allows for navigation.
- Added a styler to detect
Find()calls with string literals as the second parameter. - Added a styler/refactor for implementing abstract base class methods/properties or interfaces.
- Added a styler that leverages SQL linters for real-time feedback (ex: incorrect number of bind parameters).
- Configuration & Settings:
- Added a setting to limit the number of past snapshots kept.
- Made linter configurations per-user.
- Code Quality & Structure:
- Significant internal refactoring, breaking up
MainForminto dedicated services/managers (RefactorManager,SettingsService,TemplateManager). - Extracted
ScintillaEditorto its own file. - Switched from Git to SQLite for snapshot management.
- Quote/Parenthesis pairing is now a stable feature.
- Fixed
UndefinedVariablestyler issues (parameter handling, color format).
- Significant internal refactoring, breaking up
- Documentation & Extensibility:
- Revamped all documentation in preparation for release.
- Added a sample plugin project.
- Windows operating system
- .NET 8 Runtime or SDK
- PeopleSoft Application Designer installed and functioning
- Download the latest AppRefiner release
- Extract to a location of your choice
- Run AppRefiner.exe
- AppRefiner will automatically detect Application Designer and begin enhancing its functionality
AppRefiner provides several keyboard shortcuts that work directly within the PeopleSoft Application Designer editor window.
| Shortcut | Action |
|---|---|
| General | |
Ctrl+Shift+P |
Show Command Palette |
| Code Folding | |
Alt+Left |
Collapse current code section/level |
Alt+Right |
Expand current code section/level |
Ctrl+Alt+Left |
Collapse all top-level sections |
Ctrl+Alt+Right |
Expand all top-level sections |
| Navigation | |
Ctrl+Alt+G |
Go To Definition (Methods, Properties, etc.) |
| Linting & Analysis | |
Ctrl+Alt+L |
Lint current code |
Ctrl+. |
Apply Quick Fix (when available) |
| Refactoring | |
Ctrl+Shift+R |
Rename Variable or Method |
Ctrl+Shift+I |
Resolve Imports |
Ctrl+Shift+M |
Sort Methods |
| Templates | |
Ctrl+Alt+T |
Apply Template |
For more detailed information about AppRefiner's features and how to use them, please refer to the documentation.
AppRefiner is designed to be extensible through plugins, allowing you to create custom functionality that integrates seamlessly with the application.
You can extend AppRefiner with your own custom Stylers, Linters, and Refactors by following these steps:
- Clone or download the AppRefiner repository
- Create a new .NET 8 class library project in Visual Studio
- Add a reference to the AppRefiner project in your solution
- Create your custom classes by inheriting from the base classes:
- For Linters: Inherit from
BaseLinterorScopedLinter(for scope-aware linting) - For Stylers: Inherit from
BaseStylerorScopedStyler(for scope-aware styling) - For Refactors: Inherit from
BaseRefactororScopedRefactor(for scope-aware refactoring)
- For Linters: Inherit from
- Compile your project and copy the resulting DLL to the AppRefiner's Plugins directory
- Restart AppRefiner to load your custom plugins
Your custom functionality will appear alongside the built-in features in the Command Palette and other relevant menus.
For more detailed information about the APIs available for plugin development, refer to the Core API documentation.
If you have ideas for new Linters, Stylers, or Refactors but don't want to implement them yourself, you can open an issue on our GitHub repository. While we can't guarantee implementation of all requests, we welcome community input to help guide AppRefiner's development priorities.
If you want to build AppRefiner from source, follow these instructions:
- Windows operating system
- Visual Studio 2022 with C++ development tools installed
- .NET 8 SDK
- Java 17 or later (required for ANTLR parser generation)
- PowerShell 5.1 or higher
-
Clone the repository:
git clone https://github.com/yourusername/AppRefiner.git cd AppRefiner -
Run the build script:
# For framework-dependent build (default) .\build.ps1 # For self-contained build (includes .NET runtime) .\build.ps1 -SelfContained
-
The build script will:
- Check for required build tools
- Restore NuGet dependencies
- Build the AppRefinerHook C++ project
- Build the AppRefiner .NET project
- Copy necessary files to the output directory
- Create a ZIP file with the date in the filename
-
The output will be available in:
publish/framework/for framework-dependent buildspublish/self-contained/for self-contained builds- A ZIP file in the root directory with format
AppRefiner-yyyy-MM-dd-[type].zip
- If you encounter issues related to MSBuild not finding the C++ toolset, ensure Visual Studio 2022 with C++ development tools is properly installed.
- For .NET related errors, ensure you have the .NET 8 SDK installed by running
dotnet --version.
See the LICENSE file for details.
Contributions are welcome! Please feel free to submit a Pull Request.