Skip to content

util: athena-run: use tmp directory, fix filetype#10

Open
MacroLens wants to merge 2 commits intoAthenaFoundation:masterfrom
MacroLens:fix_athena-run
Open

util: athena-run: use tmp directory, fix filetype#10
MacroLens wants to merge 2 commits intoAthenaFoundation:masterfrom
MacroLens:fix_athena-run

Conversation

@MacroLens
Copy link

Change athena-run shell script to use the system's tmp directory rather than the ATHENA_HOME directory.
Installing athena to ATHENA_HOME that is not writeable to all users, i.e. installing athena as a shared application, makes the athena-run script useless.
By using the system's tmp directory you are able to write the temporary file needed without having write access to ATHENA_HOME.

Fixes a filetype issue when trying to load a .ath file with athena-run. Using athena-run with example.ath results in athena loading example.ath.ath. Which is unintended behavior.

Change athena-run shell script to use the system's `tmp`
directory rather than the ATHENA_HOME directory.
Installing athena to ATHENA_HOME that is not writeable
to all users, i.e. installing athena as a shared application,
makes the athena-run script useless.
By using the system's `tmp` directory you are able to write
the temporary file needed without having write access to
ATHENA_HOME.

Fixes a filetype issue when trying to load a .ath file with
athena-run. Using athena-run with example.ath results
in athena loading example.ath.ath. Which is unintended behavior.
Use a temporary with random string to avoid
collisions if multiple users are using athena-run.
@WilfredTA
Copy link
Member

Thanks for this.

The change to using system's tmp directory will break some 3rd party tooling that uses Athena. I think a backwards compatible option, which first tries ATHENA_HOME and, upon failure, utilizes system tmp directory is therefore preferred here.

I do agree with the update to allow athena-run to accept file names regardless of whether or not the input includes the .ath extension.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants