diff options
| author | littleblack111 <littleblack11111@gmail.com> | 2025-08-11 19:14:01 +0800 |
|---|---|---|
| committer | littleblack111 <littleblack11111@gmail.com> | 2025-08-11 19:14:01 +0800 |
| commit | 6a910bb63463facb7c5b72c2054740154934c7a4 (patch) | |
| tree | 73bb50bf025aff0e1b958268e283413603cc815f | |
| parent | 2941e3aad472ffb1a8ed038b5ae59eb5102b0fe6 (diff) | |
new: AGENTS.md
| -rw-r--r-- | .gitignore | 1 | ||||
| -rw-r--r-- | AGENTS.md | 57 |
2 files changed, 57 insertions, 1 deletions
@@ -1,2 +1 @@ config/WallustColors.qml -AGENTS.md diff --git a/AGENTS.md b/AGENTS.md new file mode 100644 index 0000000..79b9350 --- /dev/null +++ b/AGENTS.md @@ -0,0 +1,57 @@ +# AGENTS.md + +# THE ACTUAOL QT CODE IS QUICKSHELL +- The components that we might need/not have here, in regards or related to integrations with system etc. will need to be fetched from https://quickshell.org/docs/master, sitemap: https://quickshell.org/sitemap-0.xml +# MAKE SURE TO CHECK FETCH THE DOCS IF QUICKSHELL OR QUICKSHELL.* IS IMPORTED + +## How to Run and Test + +- To run or test the shell, use: + ``` + timeout 1 qs + ``` +- To test components triggered by IPC(if the component have anything to do with component IpcHandler), use +``` +qs msg <target> <func> <args...> +``` +for example: +``` +qs msg reload true +``` +where reload is the target and true is the argument, the argument is seperated by space + +Obviously this is IPC, meaning qs should be running already, so consider something like this: +``` +timeout 3 qs & sleep 1; qs msg reload true +``` +sleep 1 is to ensure qs is fully initialized and ready to receive messages. + (The `qs` command may not return if it succeeded, so always use a timeout.) + +- There are no automated tests or linting tools set up. + +## Code Style Guidelines + +- **Imports:** + - Do NOT add version numbers to QML import statements (e.g., use `import QtQuick`, not `import QtQuick 2.15`). + - Place all imports at the top of each QML file. + - For JavaScript utilities, use: `import "../utils/filename.js" as Name`. + +- **Formatting:** + - Use 4 spaces for indentation. + - Place properties and signals at the top of QML objects. + +- **Naming:** + - Use UpperCamelCase for QML types and components. + - Use lowerCamelCase for properties, functions, and variables. + +- **Types:** + - Always specify types for QML properties (e.g., `property int`, `property string`). + +- **Error Handling:** + - Use exceptions in JavaScript utilities for errors. + - Use comments for TODOs and known issues. + +- **General:** + - Keep code modular; use components and utility scripts. + - Add comments for complex logic or workarounds. + |
