İçeriğe geç
Kurulum

scheduled-command-automation

Yerel komutları zamanlar ve teslimini doğrular.

HamaratLabsMITv1.0.0

KURULUM

hermes skills install well-known:https://skills.hamaratlabs.com/.well-known/skills/scheduled-command-automation

Ham dosyaSKILL.md önizlemesi

3 GERÇEK ÖRNEK

Ne istendi, ne çıktı

NE İSTENDİ · 21 EKİM 2026

Her gün neler yaptığımıza bakan, kaydeden ve derecelendiren bir cron kur.

default
NE ÇIKTI

"Günlük Kod Aktivite Taraması" cron'u (her gün 23:50, LLM'siz deterministik puanlama) kuruldu; 186 commit tarandı ve puanlandı.

NE İSTENDİ · 30 KASIM 2026

Bulut depolamada her ajan için ayrı klasörle medya yedekleme yapısı kur.

depocu
NE ÇIKTI

Pilot sonrası tüm ajanların medyası yüklendi: 4676 dosya, 14,19 GB; rclone check 0 fark. Zamanlanmış yedek tanımlandı.

NE İSTENDİ · 10 KASIM 2026

Kalan kullanım kotasını izleyen bir cron kur ve doğru çalıştığından emin ol.

default
NE ÇIKTI

Var olan kota bekçisi cron'u bulundu, her çalışmada hata veren son satır düzeltildi, çalışma kaydı "ok" olarak doğrulandı.

KAYNAK VE LİSANS

Tür
HamaratLabs yazdı
Yazan
HamaratLabs
Lisans
MIT
Ham dosya
SKILL.md

DEĞERLENDİRME

  • 3ajan profilinde kullanıldı
  • 82kayıtlı yükleme
  • 3belgelenmiş örnekyalnız metin

Sayılar ajan kayıtlarından gelir. Puanlama henüz yok.

SÜRÜM

Sürüm
v1.0.0
Siteye ilk yayın
1 Aralık 2026
Oluşturma
19 Eylül 2026
Son kullanım
1 Aralık 2026
Paket
2 dosya · SKILL.md 85 satır

YORUMLAR

Yorumlar yakında

Bu skill hakkındaki yorumlar ve puanlar burada görünecek. Bölüm henüz açılmadı.

SKILL.MDÖnizleme85 SATIR

AJAN AÇIKLAMASI Use when scheduling local commands. Verify delivery.

Scheduled Command Automation

Use this skill for recurring local scripts whose stdout should be delivered to the user's channel, especially unattended nightly jobs.

Procedure

  1. Confirm the command and delivery semantics. Preserve the command exactly as provided. Treat an empty stdout result as a successful silent run; non-zero exit or timeout should remain visible as an error.
  2. Choose script-only cron when the output is fully determined by the command. Create the job with no_agent=True, a recurring cron expression, the script filename, and deliver="origin" when the requested destination is the current home channel. This removes the scheduler's additional agent pass and delivers stdout verbatim; it does not eliminate inference costs when the script itself launches agent CLIs.
  3. If the scheduler requires an allowed script root, create a thin wrapper inside $HERMES_HOME/scripts/. The wrapper must invoke the requested command without changing its arguments, forward stdout and stderr, and return the child exit code. Pass only the relative wrapper filename to the cron tool; absolute paths are rejected even when they point inside the allowed directory.
  4. Use the requested timezone explicitly when the scheduler supports it. If the cron interface has no timezone field, verify the host offset before creating the job and report the resulting offset with the next-run timestamp rather than silently assuming a timezone.
  5. Create the job through the cron management tool, not by editing scheduler storage directly. Set a human-readable name, recurring schedule, delivery target, no_agent=True, and the wrapper script. Do not add a prompt because script-only jobs ignore it.
  6. Read the job back after creation or repair. Verify the exact job, schedule, script and delivery target. For a repair, first reproduce the failing stage under the service environment, then exercise that stage against an existing authorized input. This proves only the stage, not the complete job. When a full rerun is requested, check hermes cron run --help, run hermes cron run <job_id> without weakening approvals, then use hermes cron list to confirm a new ok/completed execution and inspect its output artifact. Do not edit historical failure counters to make the job appear healthy.
  7. Report execution, coverage and delivery separately. A completed script may contain child timeouts or startup failures; a generated analysis may still misclassify their severity. Count child results from the raw records, label no-work replies separately from empty replies, and treat model incident summaries as unverified until checked. Give a concise result: what changed, what actually passed, remaining child failures, and next scheduled run. Do not claim message delivery from script success alone.

Recovering a broken rclone bisync baseline

When an Obsidian vault is synchronized by rclone bisync and the prior Path1/Path2 listings are missing, do not run a blind --resync.

  1. Run a read-only inventory with rclone check --size-only and capture --combined output; classify remote-only, local-only, and differing files.
  2. Back up remote-only and differing remote versions to a temporary recovery directory before reconciling, because resync changes the remote state.
  3. Preview the recovery with the vault as Path1 and --resync --resync-mode path1 --dry-run --max-delete 5 using the mandatory excludes: your private folders (e.g. <gizli-klasor>/**), .obsidian/**, .DS_Store.
  4. If the dry-run shows only the intended transfers and no unsafe deletions, run the same command without --dry-run.
  5. Verify with rclone check --size-only and a normal rclone bisync --dry-run; require zero differences and zero planned transfers before declaring recovery complete.
  6. Test the actual scheduled sync path once, then leave the recurring job on normal bisync without resync.

Use --resync-mode path1 only when the local vault is the declared source of truth; never infer the winner from whichever side happens to be newer. Keep --max-delete enabled so an unexpected deletion plan aborts instead of propagating silently.

For a user request such as “just sync,” execute the smallest verified sync workflow and report only the outcome, error, and verification; do not narrate internal approval or security-tool mechanics.

Mobile Google Drive Sync push/pull safety

When a phone Obsidian plugin shows a note as blank, Create, or Delete during Push, do not push first. Pull from Drive, reopen the note, and confirm its body is present; a mobile placeholder can upload as a zero-byte duplicate and overwrite or confuse the full copy.

If a push has already created duplicate remote names, inspect the exact objects with rclone lsjson and compare Size/ID; rclone size alone can hide duplicates by aggregating or selecting one object. Preserve the nonzero object, preview deletion of only the zero-byte object with rclone deletefile --dry-run, delete that exact path only after the preview targets size 0, then verify one remaining object, rclone cat content, and rclone check --size-only.

Treat an unexpected mobile Delete separately from intended deletions: remove only the intended deletion from the queue, and cancel the whole Push when the note body has not been pulled yet.

Obsidian vaults synced by Google Drive Sync

When the command writes inside an Obsidian vault using the google-drive-sync community plugin, do not assume that an Obsidian command URI or a headless terminal wrapper performs a completed pull/push. First verify a supported non-interactive sync interface; otherwise keep the cron wrapper limited to the local write, respect the user's Automatically push changes preference, and report that Drive synchronization remains a manual Obsidian action. Do not fail the research command merely because a local sync marker did not change: an unchanged marker is not proof that the write failed.

Always-on pitfalls

  • A paused job cannot be fired: the run action returns Job is paused/disabled; resume it before running and performs nothing. To pilot a not-yet-trusted job, resume it, run it, then pause it again immediately so the recurring schedule stays off while acceptance is pending.
  • Build the job and pilot it in the same session, then show the user the real output. A described contract, schedule and filter set with no executed run is not a delivered automation, and presenting it as a finished system invites a justified rejection.
  • Separate the user's task-level request from a tool's execution-approval gate. If a tool reports BLOCKED/not run, state that the command never executed and name the actual gate; do not imply the task request was unclear or ask the user to re-approve its content. Honor an explicit do-not-retry denial and never route around it through another tool.
  • Restarting the gateway (hermes gateway start) kills the process serving the current conversation, so an in-flight tool call is cut and the session reconnects afterwards. Treat it as a side-effecting action: announce it, and after the reconnect verify with hermes gateway status instead of re-running the restart.
  • When asked to "activate whichever inactive jobs can be activated", classify each [paused] job before touching it: (a) broken but fixable - reproduce by running its script once in the background (multi-profile scripts take several minutes), read the real error in the raw output (stale model id, push already resolved, bad flag), fix the cause, re-run end to end, then cronjob_manage resume; (b) paused by design awaiting the user's acceptance of a pilot (the skill that built it says "create paused, pilot, then enable") - leave it and say so; (c) its script conflicts with a standing red line (e.g. blanket --dangerously-skip-permissions) - fix the script with the user's go-ahead and leave the final activation to the user if they said they would do it. After resume, a stale next_run_at in the readback is cosmetic; verify enabled: true / state: scheduled.
  • A cron/script that commits and pushes to a specific git branch (e.g. to auto-publish generated data) must run against a worktree PERMANENTLY checked out on that target branch, never a project's primary/shared checkout - that checkout gets switched to arbitrary feature branches by other work throughout the day, so a scheduled commit can silently land on the wrong branch and never reach the pushed target. Maintain (or create once) a dedicated worktree pinned to the target branch for this purpose, and have the script fetch+pull --ff-only it before writing, to stay in sync with manual pushes made elsewhere.
  • macOS LaunchAgents for project jobs and boot daemons cannot be loaded from inside the agent's own gateway/service process (it is guarded to prevent restart loops; never switch verbs or tools to get around it). Validate plists with plutil -lint. For autostart daemons (RunAtLoad: true) that spawn persistent child processes, set <key>AbandonProcessGroup</key><true/> so launchd does not kill child processes when the startup wrapper exits. Make the startup script idempotent (check lsof -tiTCP:<port> -sTCP:LISTEN before launching) and network-resilient (loop curl against an external host before calling network APIs or tunnels). A LaunchAgent that runs a script under a privacy-protected folder (~/Desktop, ~/Documents, ~/Downloads) is denied by macOS privacy protection at boot (Operation not permitted), so the autostart silently fails after the first reboot. Do not wrap the command to sidestep that protection. Instead either move the script, its working directory and its logs to an unprotected location (e.g. ~/Library/Application Support/<app>/ or ~/.local/share/<app>/), or ask the user to grant the needed access themselves in System Settings > Privacy & Security. Add StartInterval 600 with an early silent exit 0 when the port already listens, so a crashed server comes back within 10 minutes. After any reboot, check curl on the public URL and the startup log before assuming the service is up. To test without rebooting, simulate launchd's clean environment via env -i HOME=$HOME USER=$USER /bin/bash <script>, verify endpoints, and test the already-running branch. For immediate system registration without waiting for next login/reboot, give the user ONE copy-paste launchctl bootstrap gui/$(id -u) <plist> command for their external Terminal.
  • General rule: if a guard, permission check or protection blocks an action, do not reach the same result by another route; either drop it or ask the user for explicit approval.
  • A cron job failing with a provider auth error (e.g. <provider> is not authenticated) is usually pinned to that provider at job level (the job's own provider/model setting) or inherits the profile's default cron model/provider. Check both; move the job to the profile's working provider with the scheduler's edit command (prompt and skills unchanged), back up and change the default too so future jobs do not inherit the dead provider, then run the job once and confirm which model answered from the agent's run log.
  • Keep the wrapper within the scheduler's approved scripts directory and pass a relative filename, because path validation rejects absolute or escaping paths.
  • Nightly "prepare, then ask to publish" loops use three jobs, not one. (1) a no-agent collector at the requested hour that detaches its slow agent queries and writes answers to dated files; (2) an agent job in the owning profile ~45 min later whose pre-run script prints the collected answers plus repo commits since the last real content commit (exclude the daily bot commit with git log --invert-grep --grep=<bot subject>), works ONLY in a worktree pinned to a dedicated prep branch, rebases it onto origin/main first (other agents publish to main during the day), builds, commits locally, never pushes, writes a short summary file, and answers [SILENT] when there is nothing; (3) a no-agent morning job that prints "I prepared X, shall I push?" only when origin/main..prep-branch is non-empty. For "start from tomorrow night", put a first-run date guard in the scripts instead of creating the jobs paused, and say so.
  • Publishing such a prep branch is a separate approval: rebase, build, push from the main-pinned worktree, then verify the Actions run and the live URLs.
  • Prefer no_agent for deterministic command output, because an agent session can alter formatting and spend inference tokens unnecessarily.
  • Preserve empty stdout as empty; do not add status text or a newline, because the scheduler uses empty stdout as the silent-tick gate.
  • End every silent no_agent script with an explicit exit 0. A trailing filter such as | grep -v ... exits 1 when it prints nothing, so each quiet tick is delivered to the user as a "script exited with code 1" error alert. Run the script once in the no-output case and check $? before scheduling.
  • Never source (. file) a settings file that another tool (a dashboard form, a panel) can write: it executes whatever the writer put there. Read only allow-listed keys with a strict pattern (grep -E '^KEY=[A-Za-z0-9_-]{1,40}$') and range-check numbers.
  • Verify the persisted job with a list/readback after creation, because a successful create response alone does not prove the final routing and schedule are correct.
  • Treat origin as the current conversation/home-channel destination only when that is the requested target; use an explicit platform target when the user names a different channel.
  • Do not treat a local Obsidian write as a Google Drive push: the plugin's push command is an Obsidian UI operation and may require confirmation, so never claim Drive delivery unless the remote sync is independently verified. Keep auto-push off when that is the user's preference.
  • Test the wrapped command with an empty-input/empty-queue case before promising a silent tick; a script that logs no work to stdout will still generate a delivered message.
  • Separate local command success from cloud-sync success: verify the scheduled script's exit status and output independently, because a vault write can succeed even when an interactive sync step is unavailable.
  • When the user asks for command output "exactly," report the captured stdout verbatim in a code block and keep installation fallbacks in a separate labeled block; do not silently substitute a different command for the requested one.
  • After a package install, verify the executable with both which <name> and <name> --version; inspect login/auth status without launching an interactive login when the user will authenticate separately.
  • When a watchdog/status script's job is to summarize system resource state, default to a detailed itemized breakdown (full stat decomposition - e.g. RAM's wired/active/compressed/inactive/free split, not just one "% used" number - plus a labeled top-N consumer list), not a one- or two-line summary; users tend to ask for "a more detailed table" after a terse version, and the same detailed format should serve both the periodic alert and an ad-hoc on-demand query of the same script (give the script an --always flag or similar to print full detail regardless of threshold, separate from the no_agent-watchdog's empty-stdout-unless-triggered gate).
  • When a top-process listing's names are generic interpreter binaries (python, python3, node, java), resolve each one's actual script/entry-point from its own command line (ps -p <pid> -o command=) and append it to the label before presenting the list - a bare "python3, 571 MB" tells the user nothing actionable; "python3 → v03_compose.py, 571 MB" does. Guard against leaking an inline -c script's source into the label (detect and show "(-c inline kod)" instead) rather than printing arbitrary code fragments as a process name.

Environment pitfall: service PATH

  • The gateway LaunchAgent does NOT necessarily carry ~/.local/bin on its PATH. A cron script that shells out to a tool installed there (e.g. agy) must use the absolute path; a bare name raises FileNotFoundError under the service environment while working fine in an interactive shell.
  • A cron script that hard-codes a model id must still find it in the provider's model list; when the id is removed the collection phase can succeed while only the analysis fails. Fix the constant, then re-run the whole script once before resuming the job.
  • Quota watchers: GET /v1/models can still return 200 when a monthly API spend cap is hit, whereas a zero-token POST /v1/messages/count_tokens returns HTTP 400 with the reset date; probe with the latter. If other tools read the watcher's output files, treat their format as a contract and change it only backwards-compatibly.

See references/hermes-cron-script-only.md for the wrapper and verification recipe.

VERİMLİLİK VE ARAŞTIRMA

İlişkili skill'ler

chrome-devtools-mcp-cli

browser_exec çalışmadığında izole Chrome'u CLI üzerinden sürer.

HamaratLabs1 ÖRNEK
İSTEK

Bir yarışma sunumu ve demosu için işi uygun ajanlara (Gemini/agy dahil) dağıt.

gemini-gorev

Araştırma veya görsel analiz gerektiğinde işi Gemini'ye görev olarak verir.

HamaratLabs1 ÖRNEK