termux / termux-create-package

Python script to create Termux packages easily.
https://termux.com
Apache License 2.0
430 stars 94 forks source link

Minimized code structure and fixed minor issue #24

Closed ghost closed 4 years ago

ghost commented 4 years ago

Changes

- output_file = installation_prefix + package_files[input_file_path]
+ output_file_path = os.path.join(installation_prefix, output_file_path)

Example case is, if the file entries in manifest are the following:

"files": {
  "script": ".local/bin/script",
  "LICENSE": ".local/share/LICENSES/package.txt"
}

And given the prefix is $HOME, then the former and latter will result into:

- /data/data/com.termux/files/home.local/bin/script
- /data/data/com.termux/files/home.local/share/LICENSES/package.txt
+ /data/data/com.termux/files/home/.local/bin/script
+ /data/data/com.termux/files/home/.local/share/LICENSES/package.txt