Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

move cli to src/rail/cli/rail #171

Merged
merged 4 commits into from
Dec 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ dev = [
]

[project.scripts]
rail = "rail.cli.commands:cli"
rail = "rail.cli.rail.commands:cli"

[build-system]
requires = [
Expand Down
Empty file added src/rail/cli/rail/__init__.py
Empty file.
5 changes: 5 additions & 0 deletions src/rail/cli/rail/__main__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# This file must exist with these contents
from .commands import cli

if __name__ == "__main__":
cli()
2 changes: 1 addition & 1 deletion src/rail/cli/commands.py → src/rail/cli/rail/commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import yaml

from rail.core import __version__
from rail.cli import options, scripts
from rail.cli.rail import options, scripts
from rail.interfaces.pz_factory import PZFactory
from rail.interfaces.tool_factory import ToolFactory
from rail.utils import catalog_utils
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/rail/cli/scripts.py → src/rail/cli/rail/scripts.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import rail.stages
from rail.core import RailEnv
from rail.core.stage import RailPipeline
from rail.cli.options import GitMode
from rail.cli.rail.options import GitMode
from rail.utils.path_utils import RAILDIR
from rail.utils import catalog_utils

Expand Down
2 changes: 1 addition & 1 deletion src/rail/utils/testing_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from rail.core.stage import RailStage
from rail.utils.path_utils import RAILDIR
from rail.core.data import TableHandle
from rail.cli.scripts import build_pipeline
from rail.cli.rail.scripts import build_pipeline

traindata = os.path.join(RAILDIR, "rail/examples_data/testdata/training_100gal.hdf5")
validdata = os.path.join(RAILDIR, "rail/examples_data/testdata/validation_10gal.hdf5")
Expand Down
4 changes: 2 additions & 2 deletions tests/cli/test_scripts.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import glob
import os
import pytest
from rail.cli import scripts
from rail.cli.options import args_to_dict, GitMode
from rail.cli.rail import scripts
from rail.cli.rail.options import args_to_dict, GitMode



Expand Down
Loading