HAnS is a JetBrains IDE plugin that supports feature-oriented software development by enabling developers to annotate, track, and analyze features throughout their codebase. The plugin provides comprehensive tooling for feature location, mapping, and metrics collection in software systems.
- Feature Model Language - Define hierarchical feature models using the
.feature-modelformat - Code Annotation - Annotate code fragments with feature markers using lightweight comments (
&begin[Feature],&end[Feature],&line[Feature]) - File & Folder Mapping - Map entire files or directories to features using
.feature-to-fileand.feature-to-foldermappings - Live Templates - Quick insertion of feature annotations with predefined templates
- Intelligent Completion - Context-aware code completion for feature names and annotation syntax
- Feature Model View - Visual tool window displaying the hierarchical feature structure
- Feature Metrics View - Bottom panel showing calculated metrics including:
- Line Count per feature
- Feature-to-File mappings
- Feature Scattering degree
- Feature Tangling degree
- Traffic Light Indicator - Visual indicator showing file/folder feature mapping status
- Syntax Highlighting - Custom syntax highlighting for all feature annotation languages with configurable color schemes (Darcula and Default themes)
- Smart Referencing - Navigate between feature definitions and their usages
- Feature Renaming - Rename features across the entire project with automatic reference updates
- Find Usages - Locate all occurrences of a feature throughout the codebase
- Quick Fixes - Automated fixes for unassigned features and annotation errors
- Extension Points - Plugin architecture with callbacks for metrics and feature tracking
- Service Layer - Metrics service and highlighter service for plugin extensions
- Background Tasks - Asynchronous processing for metrics calculation and feature analysis
From JetBrains Marketplace (Recommended):
Settings/Preferences > Plugins > Marketplace > Search for "HAnS" > Install
Manual Installation:
Download the latest release and install using: Settings/Preferences > Plugins > ⚙️ > Install plugin from disk...
- Supported IDEs: All JetBrains IDEs (IntelliJ IDEA, Rider, PyCharm, WebStorm, etc.)
- Minimum Build: 2025.1 (251)
- Java Version: 21+
- Create a
.feature-modelfile in your project root to define your feature hierarchy - Use live templates or quick actions to annotate code with features
- View your feature structure in the Feature Model View tool window
- Access feature metrics in the Feature Metrics View panel
- Track file/folder mappings with the traffic light indicator
We welcome contributions from the community! HAnS itself is annotated with features, serving as a practical example of the plugin's capabilities.
- Fork the repository
- Annotate your contribution - Add feature annotations to your code following the existing patterns
- Build and test - Run the
runIdeGradle task to test your changes, write unit tests when appropriate - Submit a pull request
Name your PR using this format: [Folder]-[FeatureName]-[Contributor]-[Description]
- Folder: Either
FeatureorBug - FeatureName: Use an existing feature from the feature model or propose a new one
- Contributor: Your GitHub username
- Description: Brief description of the change
All contributions are reviewed by our core team to ensure code quality and maintainability. Interested in joining the review team? Contact any current reviewer.
HAnS is developed and maintained by academic research groups focused on software engineering and feature-oriented development.
2025
-
Lightweight Visualization of Software Features with HAnS-viz by Johan Martinson, Kevin Hermann, Riman Houbbi, David Stechow, Thorsten Berger
2024
-
An IDE Plugin for Clone Management by Ahmad Al Shihabi, Jan Sollmann, Johan Martinson, Wardah Mahmood, Thorsten Berger
2021
-
Master Thesis by Johan Martinson & Herman Jansson
-
HAnS: IDE-based editing support for embedded feature annotations by Johan Martinson, Herman Jansson, Mukelabai Mukelabai, Thorsten Berger, Alexandre Bergel, and Truong Ho-Quang
Example projects using HAnS for feature annotation:
Join our Discord community for discussions, support, and updates.
See our CONTRIBUTORS.md for a full list of project contributors.
Licensed under the Apache License, Version 2.0. See LICENSE for details.