Skip to content

feat: add custom prompts panel#93

Merged
Dimillian merged 8 commits intoDimillian:mainfrom
SanderHelgesen:feature/prompts-panel
Jan 19, 2026
Merged

feat: add custom prompts panel#93
Dimillian merged 8 commits intoDimillian:mainfrom
SanderHelgesen:feature/prompts-panel

Conversation

@SanderHelgesen
Copy link
Contributor

Summary

  • initial pass at a custom prompts panel (workspace + general) with CRUD + send actions
  • wire prompt IPC + /prompts: expansion in messages
  • add panel tabs for Git / Files / Prompts

Demo

https://screen.studio/share/hJeWwB2R

Testing

  • not run (not requested)

@Dimillian
Copy link
Owner

Few things:

  • People didn't like when the app created a .codexmonitor folder in their workspace. Is it stored in the app support library .codexmontior like we do for other stuff?
  • Don't you think it's a bit a duplicate of skills?
  • But I really like the new control to switch between the files, git and your new prompts, so at least with we could get that in for git and files :)

@Dimillian
Copy link
Owner

@codex review

@Dimillian Dimillian changed the title Add custom prompts panel feat: add custom prompts panel Jan 18, 2026
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b05596da33

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@SanderHelgesen
Copy link
Contributor Author

Few things:

  • People didn't like when the app created a .codexmonitor folder in their workspace. Is it stored in the app support library .codexmontior like we do for other stuff?
  • Don't you think it's a bit a duplicate of skills?
  • But I really like the new control to switch between the files, git and your new prompts, so at least with we could get that in for git and files :)
  • I see - for workspace-specific prompts it currently saves to the .codexmonitor directory inside the workspace. I could look into moving it to app support instead if you or others see the use for something like this. I find myself running a lot of pre-defined prompts.
  • You're right that they're similar. The reason I went with prompts rather than skills is that skills can be invoked by agents automatically, while prompts are purely user-triggered shortcuts. That said, skills could be a natural next tab or sub tab here, where SkillsManager would fit perfectly.
  • Glad you liked the tab control! It actually took me some time to realize the original was clickable.

@Dimillian
Copy link
Owner

Yes I think the blocking thing for me is really the workspace write, look how I've moved the worktree, you can probably use same kind of folder structure

@SanderHelgesen
Copy link
Contributor Author

Updated workspace prompts to live under app data (workspaces//prompts) so no workspace writes, mirroring the worktree layout. Also rejected whitespace in prompt names to match slash parsing. Global prompts stay in CODEX_HOME.

@Dimillian
Copy link
Owner

@codex review

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 086392e765

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +385 to +389
let target = PathBuf::from(path);
if !target.exists() {
return Ok(());
}
fs::remove_file(&target).map_err(|err| err.to_string())

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Restrict prompt file paths before deletion

The new prompt commands accept a raw path from the renderer and immediately act on it, so any caller that can invoke Tauri commands (e.g., via XSS or a compromised preload) can delete arbitrary files on disk by pointing path outside the prompts directories; the same pattern appears in prompts_update/prompts_move for writes and renames. This is a security footgun introduced with the new prompts CRUD and should be gated to workspace/global prompts roots or rejected when the path is outside those directories.

Useful? React with 👍 / 👎.

Comment on lines +423 to +426
if let Some(parent) = next_path.parent() {
fs::create_dir_all(parent).map_err(|err| err.to_string())?;
}
fs::rename(&target_path, &next_path).map_err(|err| err.to_string())?;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P3 Badge Handle cross-filesystem moves for prompts

prompts_move uses fs::rename directly, which fails with EXDEV when the workspace prompts directory (app data) and the global prompts directory (CODEX_HOME) live on different filesystems (e.g., CODEX_HOME on an external drive). In that case the UI will always error and the prompt cannot be moved; a copy+delete fallback is needed for cross-volume moves.

Useful? React with 👍 / 👎.

@Dimillian Dimillian merged commit d49379a into Dimillian:main Jan 19, 2026
2 checks passed
gersmann pushed a commit to gersmann/codex-monitor-web that referenced this pull request Mar 10, 2026
Co-authored-by: Thomas Ricouard <ricouard77@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants