Files
ProgrammingLanguages/PA005
2023-03-30 19:32:14 -06:00
..
2023-03-23 13:24:07 -06:00
2023-03-30 19:30:33 -06:00
2023-03-23 13:24:28 -06:00
2023-03-30 19:30:41 -06:00
2023-03-30 19:31:10 -06:00
2023-03-30 19:32:14 -06:00
2023-03-23 12:55:01 -06:00
2023-03-23 13:24:28 -06:00

Usage

Testing each language

  1. setup the perl dependency
make

or

make setup_perl
  1. run all the tests. This will print the result of each language then print the original file.
make test
  1. Run individual tests
make test_python
make test_perl
make test_java
  1. Delete output files
make clean

Executing The python program

  1. Usage
# Only the input file path is a required positional argument. 
# If the output is left out it will print it to stdout
usage: clean_file.py [-h] [-o OUTPUT_FILE_PATH] input_file_path
  1. Examples
python3 clean_file.py test.txt
python3 clean_file.py test.txt -o out.txt

Executing The perl program

  1. Usage
# Only the input file path is a required argument. 
# If the output is left out it will print it to stdout
Usage: clean_file.pl --input_file_path INPUT_FILE_PATH [--output_file_path OUTPUT_FILE_PATH]

  1. Examples
perl clean_file.pl --input_file_path test.txt
perl clean_file.pl --input_file_path test.txt --output_file_path out.txt

Executing The java program

  1. Usage
# Only the input file path is a required positional argument. 
# If the output is left out it will print it to stdout
Usage: CleanFile <input_file_path> [<output_file_path>]

  1. Examples
java CleanFile.java test.txt
java CleanFile.java test.txt out.txt