# Path: lib/fs.py
# def check_if_available(prg, msg):
# 
# Path: lib/process.py
# def get_simple_cmd_output(cmd, stderr=STDOUT):
#     """Execute a simple external command and get its output.
# 
#     The command contains no pipes. Error messages are
#     redirected to the standard output by default.
#     """
#     args = shlex.split(cmd)
#     return Popen(args, stdout=PIPE, stderr=stderr).communicate()[0].decode("utf8")


import os
import sys
import config as cfg
from pathlib import Path
from lib import fs
from lib.process import get_simple_cmd_output
#!/usr/bin/env python3

"""
A simple script that changes the character
encoding of the input file to UTF-8.

The result is printed to the screen.

Last update: 2017-12-16 (yyyy-mm-dd)
"""




# Path: lib/fs.py
# def check_if_available(prg, msg):
# 
# Path: lib/process.py
# def get_simple_cmd_output(cmd, stderr=STDOUT):
#     """Execute a simple external command and get its output.
# 
#     The command contains no pipes. Error messages are
#     redirected to the standard output by default.
#     """
#     args = shlex.split(cmd)
#     return Popen(args, stdout=PIPE, stderr=stderr).communicate()[0].decode("utf8")


# Path: to_utf8.py
import os
import sys
import config as cfg
from pathlib import Path
from lib import fs
from lib.process import get_simple_cmd_output

#!/usr/bin/env python3

"""
A simple script that changes the character
encoding of the input file to UTF-8.

The result is printed to the screen.

Last update: 2017-12-16 (yyyy-mm-dd)
"""




fs.check_if_available(cfg.FILE, "Error: {} is not available!".format(cfg.FILE))