Fix CLI/output/packaging issues for Galaxy/Bioconda integration#2
Merged
Conversation
Adds --version flag, makes input-type detection content-based instead of extension-based, and makes the junction/BAM output options accept a file path for single inputs. Bumps to 2.1.0. - Add --version (CLI11 set_version_flag) sourced from a configured version.hpp generated from the CMake project VERSION, so the git tag, CMake version, --version output and conda package can't drift. A CI job fails on any CMakeLists.txt vs conda/meta.yaml version mismatch. - Detect input type by content, not extension (Galaxy names every dataset *.dat): --bam by magic bytes (BGZF/BAM, CRAM, SAM), --bed by content (BED record vs list of existing paths). Add explicit --bam_list/--bed_list; auto-detected path lists still work but warn. (Issue #2) - Fix is_file_path npos bug so bare output filenames (out.bed, out.bam) are treated as files, not directories. Move it to a shared path_utils helper and use it in OutputWriter. (Issues #1, #3, #4) - --out_original_junctions now accepts a file path for a single input and is implemented for GTF/BED (previously directory-only for BAM and a silent no-op for GTF/BED). (Issues #1, #3) - --out_filtered_bam accepts a file path for a single BAM input; fix generate_bam_output_paths multi-input parent-dir fallback. (Issue #4) - Add GitHub Actions CI (x86_64, linux-aarch64, osx-arm64) + tests for path generation and content detection (incl. a *.dat input case). - Update README output-option docs (file vs directory, the --removed_alignments_bam suffix) and add CHANGELOG. Closes #1 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
pkg-config sets HTSLIB_LIBRARIES to the bare "hts" and the directory in HTSLIB_LIBRARY_DIRS, which is not on the default linker search path on macOS (Homebrew's /opt/homebrew/lib), causing "ld: library 'hts' not found". Add the dir via target_link_directories. Surfaced by the new macos-latest CI job. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes several CLI/output/packaging issues found while wrapping EASTR as a Galaxy tool, so the wrapper can drop its workarounds. Bumps to 2.1.0.
Changes
--versionflag (CLI11set_version_flag) sourced from a configuredversion.hppgenerated from the CMakeproject(... VERSION ...)— a single source of truth, so the git tag, CMake version,--versionoutput, and conda package can't drift. A CI job fails on anyCMakeLists.txtvsconda/meta.yamlmismatch. (required for Galaxy provenance)Content-based input detection (issue Fix CLI/output/packaging issues for Galaxy/Bioconda integration #2). Input type is detected by file content, not extension, so inputs work regardless of name (Galaxy names every dataset
*.dat):--bamby magic bytes (BGZF/BAM, CRAM, SAM)--bedby content (a BED record vs. a list of existing paths)--bam_list/--bed_listflags; auto-detected path lists still work but emit a deprecation warning.Output options accept a file path for single inputs (issues junction output are readin as .bed but not PATH #1, Fix --out_filtered_bam <file> creating a directory for a single BAM (2.1.1) #3, #4):
is_file_pathnposbug where bare filenames (out.bed,out.bam) were misread as directories. Moved to a sharedpath_utilshelper used byOutputWriter.--out_original_junctionsnow accepts a file path for a single input and is implemented for GTF/BED (was directory-only for BAM and a silent no-op for GTF/BED). Directory mode kept for multi-input.--out_filtered_bamaccepts a file path for a single BAM; fixed thegenerate_bam_output_pathsmulti-input parent-dir fallback.ARM64 / CI (issue #5): added GitHub Actions CI building + testing on
ubuntu-latest(x86_64),ubuntu-24.04-arm(linux-aarch64), andmacos-latest(osx-arm64). The code already had the minimap2sse2neonpath for ARM.Docs/tests: README output-option docs clarified (file vs directory, the
--removed_alignments_bam_removed_alignments.bamsuffix); new unit tests for path generation and content detection (incl. a*.datinput case);CHANGELOG.mdadded.Follow-ups (not in this PR)
v2.1.0and update thesha256inconda/meta.yaml.bioconda-recipesPR addingadditional_platforms: [linux-aarch64].Closes #1