Skip to content

Commit

Permalink
Re-add deprecated scripts, drop shebang from cli modules (#187)
Browse files Browse the repository at this point in the history
This is a follow-up change to re-add deprecated scripts so we don't
break any existing use of those scripts while folks migrate to better
ways to invoke them.

Additionally, we can drop the shebangs and executable permissions from
the CLI modules that were renamed in the previous commit.
  • Loading branch information
cottsay authored Jun 28, 2024
1 parent 8de70e4 commit 516507c
Show file tree
Hide file tree
Showing 16 changed files with 88 additions and 16 deletions.
11 changes: 11 additions & 0 deletions scripts/rosdistro
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/usr/bin/env python3

import sys

from rosdistro.cli.rosdistro import main

if __name__ == '__main__':
print('The rosdistro script is deprecated. Use python3 '
"-m 'rosdistro.cli.rosdistro' instead.\n",
file=sys.stderr)
sys.exit(main())
11 changes: 11 additions & 0 deletions scripts/rosdistro_build_cache
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/usr/bin/env python3

import sys

from rosdistro.cli.rosdistro_build_cache import main

if __name__ == '__main__':
print('The rosdistro_build_cache script is deprecated. Use python3 '
"-m 'rosdistro.cli.rosdistro_build_cache' instead.\n",
file=sys.stderr)
sys.exit(main())
11 changes: 11 additions & 0 deletions scripts/rosdistro_convert
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/usr/bin/env python3

import sys

from rosdistro.cli.rosdistro_convert import main

if __name__ == '__main__':
print('The rosdistro_convert is deprecated. Use python3 '
"-m 'rosdistro.cli.rosdistro_convert' instead.\n",
file=sys.stderr)
sys.exit(main())
11 changes: 11 additions & 0 deletions scripts/rosdistro_freeze_source
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/usr/bin/env python3

import sys

from rosdistro.cli.rosdistro_freeze_source import main

if __name__ == '__main__':
print('The rosdistro_freeze_source script is deprecated. Use python3 '
"-m 'rosdistro.cli.rosdistro_freeze_source' instead.\n",
file=sys.stderr)
sys.exit(main())
11 changes: 11 additions & 0 deletions scripts/rosdistro_generate_cache
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/usr/bin/env python3

import sys

from rosdistro.cli.rosdistro_generate_cache import main

if __name__ == '__main__':
print('The rosdistro_generate_cache script is deprecated. Use python3 '
"-m 'rosdistro.cli.rosdistro_generate_cache' instead.\n",
file=sys.stderr)
sys.exit(main())
11 changes: 11 additions & 0 deletions scripts/rosdistro_migrate_to_rep_141
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/usr/bin/env python3

import sys

from rosdistro.cli.rosdistro_migrate_to_rep_141 import main

if __name__ == '__main__':
print('The rosdistro_migrate_to_rep_141 script is deprecated. Use python3 '
"-m 'rosdistro.cli.rosdistro_migrate_to_rep_141' instead.\n",
file=sys.stderr)
sys.exit(main())
11 changes: 11 additions & 0 deletions scripts/rosdistro_migrate_to_rep_143
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/usr/bin/env python3

import sys

from rosdistro.cli.rosdistro_migrate_to_rep_143 import main

if __name__ == '__main__':
print('The rosdistro_migrate_to_rep_143 script is deprecated. Use python3 '
"-m 'rosdistro.cli.rosdistro_migrate_to_rep_143' instead.\n",
file=sys.stderr)
sys.exit(main())
11 changes: 11 additions & 0 deletions scripts/rosdistro_reformat
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/usr/bin/env python3

import sys

from rosdistro.cli.rosdistro_reformat import main

if __name__ == '__main__':
print('The rosdistro_reformat script is deprecated. Use python3 '
"-m 'rosdistro.cli.rosdistro_reformat' instead.\n",
file=sys.stderr)
sys.exit(main())
2 changes: 0 additions & 2 deletions src/rosdistro/cli/rosdistro.py
100755 → 100644
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
#!/usr/bin/env python3

import optparse
import sys

Expand Down
2 changes: 0 additions & 2 deletions src/rosdistro/cli/rosdistro_build_cache.py
100755 → 100644
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
#!/usr/bin/env python3

# Software License Agreement (BSD License)
#
# Copyright (c) 2013, Open Source Robotics Foundation, Inc.
Expand Down
2 changes: 0 additions & 2 deletions src/rosdistro/cli/rosdistro_convert.py
100755 → 100644
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
#!/usr/bin/env python3

# Software License Agreement (BSD License)
#
# Copyright (c) 2013, Open Source Robotics Foundation, Inc.
Expand Down
2 changes: 0 additions & 2 deletions src/rosdistro/cli/rosdistro_freeze_source.py
100755 → 100644
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
#!/usr/bin/env python3

# Software License Agreement (BSD License)
#
# Copyright (c) 2016, Clearpath Robotics
Expand Down
2 changes: 0 additions & 2 deletions src/rosdistro/cli/rosdistro_generate_cache.py
100755 → 100644
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
#!/usr/bin/env python3

import optparse
import sys

Expand Down
2 changes: 0 additions & 2 deletions src/rosdistro/cli/rosdistro_migrate_to_rep_141.py
100755 → 100644
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
#!/usr/bin/env python3

import argparse
import gzip
import os
Expand Down
2 changes: 0 additions & 2 deletions src/rosdistro/cli/rosdistro_migrate_to_rep_143.py
100755 → 100644
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
#!/usr/bin/env python3

import argparse
import sys

Expand Down
2 changes: 0 additions & 2 deletions src/rosdistro/cli/rosdistro_reformat.py
100755 → 100644
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
#!/usr/bin/env python3

# Software License Agreement (BSD License)
#
# Copyright (c) 2013, Open Source Robotics Foundation, Inc.
Expand Down

0 comments on commit 516507c

Please sign in to comment.