mirror of
https://github.com/openai/codex.git
synced 2026-04-25 15:15:15 +00:00
feat: support product-scoped plugins. (#15041)
1. Added SessionSource::Custom(String) and --session-source. 2. Enforced plugin and skill products by session_source. 3. Applied the same filtering to curated background refresh.
This commit is contained in:
@@ -25,6 +25,7 @@ async fn plugin_read_returns_plugin_details_with_bundle_contents() -> Result<()>
|
||||
std::fs::create_dir_all(repo_root.path().join(".agents/plugins"))?;
|
||||
std::fs::create_dir_all(plugin_root.join(".codex-plugin"))?;
|
||||
std::fs::create_dir_all(plugin_root.join("skills/thread-summarizer"))?;
|
||||
std::fs::create_dir_all(plugin_root.join("skills/chatgpt-only"))?;
|
||||
std::fs::write(
|
||||
repo_root.path().join(".agents/plugins/marketplace.json"),
|
||||
r#"{
|
||||
@@ -79,6 +80,32 @@ description: Summarize email threads
|
||||
---
|
||||
|
||||
# Thread Summarizer
|
||||
"#,
|
||||
)?;
|
||||
std::fs::write(
|
||||
plugin_root.join("skills/chatgpt-only/SKILL.md"),
|
||||
r#"---
|
||||
name: chatgpt-only
|
||||
description: Visible only for ChatGPT
|
||||
---
|
||||
|
||||
# ChatGPT Only
|
||||
"#,
|
||||
)?;
|
||||
std::fs::create_dir_all(plugin_root.join("skills/thread-summarizer/agents"))?;
|
||||
std::fs::write(
|
||||
plugin_root.join("skills/thread-summarizer/agents/openai.yaml"),
|
||||
r#"policy:
|
||||
products:
|
||||
- CODEX
|
||||
"#,
|
||||
)?;
|
||||
std::fs::create_dir_all(plugin_root.join("skills/chatgpt-only/agents"))?;
|
||||
std::fs::write(
|
||||
plugin_root.join("skills/chatgpt-only/agents/openai.yaml"),
|
||||
r#"policy:
|
||||
products:
|
||||
- CHATGPT
|
||||
"#,
|
||||
)?;
|
||||
std::fs::write(
|
||||
|
||||
Reference in New Issue
Block a user