Skip to content

Add CLI command to add features#748

Merged
garrettjstevens merged 3 commits intomainfrom
cli_feature_add
Dec 16, 2025
Merged

Add CLI command to add features#748
garrettjstevens merged 3 commits intomainfrom
cli_feature_add

Conversation

@garrettjstevens
Copy link
Contributor

When trying to test #747, I realized there wasn't a CLI command to add a top-level feature. I needed one to properly test that PR, and it seems like a general-purpose command, so I added it.

You can add a simple feature with the --min, --max, --type, etc. flags, or a more complex feature from JSON, which can be in a file or read from stdin.

apollo feature add <<EOF
{
  "assembly": "vv1",
  "refSeq": "ctgA",
  "min": 301,
  "max": 310,
  "type": "match",
  "attributes": {"gff_id": ["match1"]},
  "children": [
    {
      "min": 301,
      "max": 305,
      "type": "match_part",
      "attributes": {"gff_id": ["matchPart1"]}
    }
  ]
}
EOF

@garrettjstevens garrettjstevens self-assigned this Dec 15, 2025
@garrettjstevens garrettjstevens merged commit 9412753 into main Dec 16, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

Comments