Python日期区间按季度拆分脚本
编写Python 2脚本,将指定的日期范围按照季度标准拆分为多个子区间,并支持输出季度标签(如YYYYQ#)。
npx skills add ECNU-ICALK/AutoSkill --skill python日期区间按季度拆分脚本 --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
# Python日期区间按季度拆分脚本 编写Python 2脚本,将指定的日期范围按照季度标准拆分为多个子区间,并支持输出季度标签(如YYYYQ#)。 ## Prompt # Role & Objective 编写Python 2脚本,用于将输入的日期区间按季度进行拆分。 # Operational Rules & Constraints 1. 输入格式:起始日期和结束日期(字符串格式 YYYY-MM-DD)。 2. 拆分逻辑:从起始日期开始,计算当前季度的结束日期(3月31日、6月30日、9月30日、12月31日)。 3. 边界处理:如果计算出的季度结束日期超过了输入的结束日期,则使用输入的结束日期作为该区间的结束。 4. 输出格式:默认输出格式为 "YYYY-MM-DD - YYYY-MM-DD"。 5. 季度标注:如果用户要求注明季度,需在输出字符串后追加季度标识(例如 "2023Q1")。 6. 语法要求:必须使用 Python 2 语法(例如 print 语句不加括号)。 # Anti-Patterns - 不要使用 Python 3 特有的语法。 - 不要忽略跨年的日期区间处理。 # Examples 输入:2023-10-01 到 2024-04-17 输出: 2023-10-01 - 2023-12-31, 2023Q4 2024-01-01 - 2024-03-31, 2024Q1 2024-04-01 - 2024-04-17, 2024Q2 ## Triggers - python2 日期区间按季度拆分 - 将日期范围按季度分割脚本 - 生成季度日期区间 - 日期季度拆分并标注
- Prompt
- Triggers
What does the Python日期区间按季度拆分脚本 skill do?
编写Python 2脚本,将指定的日期范围按照季度标准拆分为多个子区间,并支持输出季度标签(如YYYYQ#)。
How do I install it?
Run `npx skills add ECNU-ICALK/AutoSkill --skill python日期区间按季度拆分脚本 --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From ECNU-ICALK/AutoSkill, a repository with 539 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.
