- Home
- Skills
- Interstellar Code
- Claud Skills
- Time Helper
time-helper_skill
- Python
11
GitHub Stars
3
Bundled Files
2 months ago
Catalog Refreshed
4 months ago
First Indexed
Readme & install
Copy the install command, review bundled files from the catalogue, and read any extended description pulled from the listing source.
Installation
Preview and clipboard use veilstrat where the catalogue uses aiagentskills.
npx veilstrat add skill interstellar-code/claud-skills --skill time-helper- README.md2.5 KB
- skill.md11.5 KB
- time-helper.php9.2 KB
Overview
This skill provides fast, cross-platform time and timezone operations implemented in native PHP. It returns current time, converts between timezones, performs add/subtract calculations, lists timezones, and checks DST status without external services. The design prioritizes token efficiency and works on Windows, macOS, and Linux with PHP 7.4+.
How this skill works
I parse the user intent (now, convert, add/subtract, list, dst), extract parameters (time, timezone, offset), then run a small PHP script that uses DateTimeImmutable and DateTimeZone to produce results. Outputs are formatted for clarity and minimal colored-output calls are used for headers and final status to avoid CLI flicker.
When to use it
- Get the current local time for any IANA timezone (Asia/Tokyo, America/New_York, etc.).
- Convert a specific time between two timezones, including date rollovers and DST adjustments.
- Add or subtract hours, days, weeks, or months from a base time or now.
- List available timezones, optionally filtered by region (America, Europe, Asia).
- Check whether a timezone is currently observing daylight saving time and view UTC offset.
Best practices
- Provide full IANA timezone identifiers when possible (e.g., America/New_York) to avoid ambiguity.
- Keep colored-output calls minimal: one header and one final status call per operation to prevent CLI flicker.
- Validate input formats (use 24-hour or 12-hour with AM/PM) and prefer ISO-like date strings for conversions.
- Use the list command to discover exact timezone names if an input is rejected.
- Run basic tests locally (php time-helper.php now UTC, convert, add, list, dst) after installing or upgrading PHP.
Example use cases
- Ask "what time is it in Tokyo" to get current time, timezone name, and UTC offset.
- Convert a meeting time: "convert 3pm America/New_York to Asia/Tokyo" and get the converted time and date.
- Schedule calculations: "what is 30 days from now" to get an exact future date/time in UTC or a target timezone.
- Audit timezones: "list America" to see all America/* timezone identifiers and counts.
- Verify DST: "is Europe/Paris in daylight saving" to receive DST active status, offset, and abbreviation.
FAQ
PHP 7.4+ is required; PHP 8.x is recommended for best compatibility.
What if a timezone string is invalid?
The skill returns a clear error and suggests running the list command to find the correct IANA timezone name.
How many colored-output calls should I use per command?
Limit to 2 calls: one skill-header at the start and one success/error at the end to avoid CLI flicker.