Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue with changing directory #1

Open
MohammadHuseyn opened this issue Jul 22, 2024 · 2 comments
Open

Issue with changing directory #1

MohammadHuseyn opened this issue Jul 22, 2024 · 2 comments

Comments

@MohammadHuseyn
Copy link

MohammadHuseyn commented Jul 22, 2024

after running

sh Arch_Persianizer.sh

got:

Arch_Persianizer.sh: line 40: cd: xkb-switch: No such file or directory
Error: could not directory xkb-switch

The problem is the direcory path in line 40:

  cd "$dir" || { echo "Error: could not directory $dir"; exit 1; }
@MohammadHuseyn
Copy link
Author

A way to solve this:
adding these lines before the line that causes the error:

curr_dir=$(pwd)
echo "curr_dir: $curr_dir"

and changing the line like this:

  cd "$curr_dir/$dir" || { echo "Error: could not directory $dir"; exit 1; }

@wolandark
Copy link
Owner

I can't reproduce this issue. I just tested the script in an Arch Linux docker container without any issues, it must be on your end!

I just ran some tests both with bash <(curl -s https://raw.githubusercontent.com/wolandark/Arch-Persianizer/master/Arch_Persianizer.sh) and with sh Arch_Persianizer.sh and ./Arch_Persianizer.sh after downloading the script, and I saw no issues whatsoever.

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

No branches or pull requests

2 participants