# Datalad Push

> >

- **Type:** Skill
- **Install:** `agentstack add skill-neuroanalytics-data-science-harness-datalad-push`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [neuroanalytics](https://agentstack.voostack.com/s/neuroanalytics)
- **Installs:** 0
- **Category:** [Agent Skills](https://agentstack.voostack.com/c/agent-skills)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [neuroanalytics](https://github.com/neuroanalytics)
- **Source:** https://github.com/neuroanalytics/data-science-harness/tree/main/plugins/datalad-cli/skills/datalad-push

## Install

```sh
agentstack add skill-neuroanalytics-data-science-harness-datalad-push
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# Skill: datalad-push

Transfer saved dataset state — git history and/or annexed file content — to a configured
sibling (remote). Respects publish-depends ordering so annexed data reaches storage
before git history reaches the git host.

## Steps

1. **Verify DataLad context** — check for `.datalad/` in the current directory or a
   parent:
   ```bash
   ls .datalad/ 2>/dev/null
   ```
   If no dataset is found, inform the user and stop.

2. **Check for uncommitted changes** — run `datalad status`:
   ```bash
   datalad status
   ```
   If the working tree is dirty, warn:
   > "There are unsaved changes. Push will only transfer already-committed state. Save
   > first with `datalad save -m '...'`?"
   Wait for the user to save or confirm they want to push the current committed state.

3. **Identify target sibling** — read from `$ARGUMENTS`. If not provided, list available
   siblings and ask which one to push to:
   ```bash
   datalad siblings
   ```

4. **Determine data mode** — present the choice:
   - **auto-if-wanted** (default): pushes only content the sibling has declared it wants
     via its `annex-wanted` expression. This is the default but **only works when the
     sibling has `annex-wanted` configured** — if not configured, no content will be pushed
   - **nothing**: push git history only, skip all annexed content
   - **anything**: push all locally present annexed content regardless of wanted rules

   Ask if annexed data handling is unclear from context.

5. **Determine recursion** — ask if the user wants to push subdatasets too:
   > "Push subdatasets recursively as well? (`-r`)"
   If yes, also mention `--on-failure ignore` — without it a single subdataset failure
   aborts the entire recursive push. With it, failures are logged and the push continues
   across remaining subdatasets.

6. **Construct and show command**:
   ```
   datalad push --to  [--data {nothing|anything|auto-if-wanted}] [-r]
   ```
   Show the full command before executing.

7. **Execute and report** — run the command. Report:
   - Which git refs were pushed
   - How many annexed objects were transferred (if any)
   - If a `--publish-depends` sibling was pushed first, note that too

## Reference

Load `${CLAUDE_PLUGIN_ROOT}/../references/siblings-and-remotes.md` for publish-depends
ordering, `--data` mode details, and why annexed content must reach storage before git
history reaches the git host.

Load `${CLAUDE_PLUGIN_ROOT}/../references/global-options.md` when the user asks about
`--on-failure` for recursive pushes, wants JSON output from push results, or needs to
debug a failed push (`-l debug`).

## Constraints

- Always check for a dirty working tree before pushing — never push without this check.
- Always show the full command before executing.
- Warn if the target sibling has no `--publish-depends` configured and annexed content
  is present in the dataset:
  > "This sibling has no storage dependency configured. Annexed file content may not be
  > accessible to consumers who clone the git history. Consider setting up a storage
  > sibling and adding `--publish-depends`."
- Never use `git push` directly inside a DataLad dataset — it bypasses annexed content
  handling and publish-depends ordering.

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [neuroanalytics](https://github.com/neuroanalytics)
- **Source:** [neuroanalytics/data-science-harness](https://github.com/neuroanalytics/data-science-harness)
- **License:** MIT

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-neuroanalytics-data-science-harness-datalad-push
- Seller: https://agentstack.voostack.com/s/neuroanalytics
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
