Setting a variable to a path to a program then running the variable does not run the program [on hold]












0














I have a program on /usr/local/bin/prog1 and the data directory already on /usr/local/lib/python2.7/dist-packages/prog1.



I try to set up the environments to run prog1 like this:



PROG1=/usr/local/lib/python2.7/dist-packages/prog1:/usr/local/bin/prog1
export PROG1


But when I run PROG1, the output errors appears:



$ PROG1
PROG1: command not found


OR I try to run $PROG1, the output errors appears:



$ $PROG1
-bash: /usr/local/lib/python2.7/dist-packages/prog1:/usr/local/bin/prog1: No such file or directory


How can I run my Prog1 on my portable environments??



Thanks in advance.










share|improve this question















put on hold as unclear what you're asking by wjandrea, Zanna, pomsky, Eric Carvalho, abu-ahmed al-khatiri 6 hours ago


Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.











  • 3




    "data directory" meaning what exactly? /usr/local/bin should already be in the default PATH and python should search /usr/local/lib/python2.7/dist-packages for modules by default - what exactly doesn't work if you simply type prog1?
    – steeldriver
    Dec 29 '18 at 18:13






  • 1




    This is an XY problem as suggested by steeldriver's comment. Voting to close as unclear
    – Zanna
    Dec 30 '18 at 19:22












  • @steeldriver Zanna "data directory" are the directory of my prog1 python. what i do to add a information you need to clear my question?
    – abu-ahmed al-khatiri
    yesterday










  • @abu-ahmedal-khatiri please add the error messages that you get when you try to run prog1 (note not PROG1 - Linux is case-sensitive)
    – steeldriver
    yesterday










  • prog1 --address --port successfully running but it need to reading my prog1 python directory as /usr/local/lib/python2.7/dist-packages/prog1, well i need to make a portable environments @steeldriver
    – abu-ahmed al-khatiri
    yesterday
















0














I have a program on /usr/local/bin/prog1 and the data directory already on /usr/local/lib/python2.7/dist-packages/prog1.



I try to set up the environments to run prog1 like this:



PROG1=/usr/local/lib/python2.7/dist-packages/prog1:/usr/local/bin/prog1
export PROG1


But when I run PROG1, the output errors appears:



$ PROG1
PROG1: command not found


OR I try to run $PROG1, the output errors appears:



$ $PROG1
-bash: /usr/local/lib/python2.7/dist-packages/prog1:/usr/local/bin/prog1: No such file or directory


How can I run my Prog1 on my portable environments??



Thanks in advance.










share|improve this question















put on hold as unclear what you're asking by wjandrea, Zanna, pomsky, Eric Carvalho, abu-ahmed al-khatiri 6 hours ago


Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.











  • 3




    "data directory" meaning what exactly? /usr/local/bin should already be in the default PATH and python should search /usr/local/lib/python2.7/dist-packages for modules by default - what exactly doesn't work if you simply type prog1?
    – steeldriver
    Dec 29 '18 at 18:13






  • 1




    This is an XY problem as suggested by steeldriver's comment. Voting to close as unclear
    – Zanna
    Dec 30 '18 at 19:22












  • @steeldriver Zanna "data directory" are the directory of my prog1 python. what i do to add a information you need to clear my question?
    – abu-ahmed al-khatiri
    yesterday










  • @abu-ahmedal-khatiri please add the error messages that you get when you try to run prog1 (note not PROG1 - Linux is case-sensitive)
    – steeldriver
    yesterday










  • prog1 --address --port successfully running but it need to reading my prog1 python directory as /usr/local/lib/python2.7/dist-packages/prog1, well i need to make a portable environments @steeldriver
    – abu-ahmed al-khatiri
    yesterday














0












0








0







I have a program on /usr/local/bin/prog1 and the data directory already on /usr/local/lib/python2.7/dist-packages/prog1.



I try to set up the environments to run prog1 like this:



PROG1=/usr/local/lib/python2.7/dist-packages/prog1:/usr/local/bin/prog1
export PROG1


But when I run PROG1, the output errors appears:



$ PROG1
PROG1: command not found


OR I try to run $PROG1, the output errors appears:



$ $PROG1
-bash: /usr/local/lib/python2.7/dist-packages/prog1:/usr/local/bin/prog1: No such file or directory


How can I run my Prog1 on my portable environments??



Thanks in advance.










share|improve this question















I have a program on /usr/local/bin/prog1 and the data directory already on /usr/local/lib/python2.7/dist-packages/prog1.



I try to set up the environments to run prog1 like this:



PROG1=/usr/local/lib/python2.7/dist-packages/prog1:/usr/local/bin/prog1
export PROG1


But when I run PROG1, the output errors appears:



$ PROG1
PROG1: command not found


OR I try to run $PROG1, the output errors appears:



$ $PROG1
-bash: /usr/local/lib/python2.7/dist-packages/prog1:/usr/local/bin/prog1: No such file or directory


How can I run my Prog1 on my portable environments??



Thanks in advance.







18.04 bash






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited yesterday

























asked Dec 29 '18 at 17:40









abu-ahmed al-khatiri

90015




90015




put on hold as unclear what you're asking by wjandrea, Zanna, pomsky, Eric Carvalho, abu-ahmed al-khatiri 6 hours ago


Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.






put on hold as unclear what you're asking by wjandrea, Zanna, pomsky, Eric Carvalho, abu-ahmed al-khatiri 6 hours ago


Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.










  • 3




    "data directory" meaning what exactly? /usr/local/bin should already be in the default PATH and python should search /usr/local/lib/python2.7/dist-packages for modules by default - what exactly doesn't work if you simply type prog1?
    – steeldriver
    Dec 29 '18 at 18:13






  • 1




    This is an XY problem as suggested by steeldriver's comment. Voting to close as unclear
    – Zanna
    Dec 30 '18 at 19:22












  • @steeldriver Zanna "data directory" are the directory of my prog1 python. what i do to add a information you need to clear my question?
    – abu-ahmed al-khatiri
    yesterday










  • @abu-ahmedal-khatiri please add the error messages that you get when you try to run prog1 (note not PROG1 - Linux is case-sensitive)
    – steeldriver
    yesterday










  • prog1 --address --port successfully running but it need to reading my prog1 python directory as /usr/local/lib/python2.7/dist-packages/prog1, well i need to make a portable environments @steeldriver
    – abu-ahmed al-khatiri
    yesterday














  • 3




    "data directory" meaning what exactly? /usr/local/bin should already be in the default PATH and python should search /usr/local/lib/python2.7/dist-packages for modules by default - what exactly doesn't work if you simply type prog1?
    – steeldriver
    Dec 29 '18 at 18:13






  • 1




    This is an XY problem as suggested by steeldriver's comment. Voting to close as unclear
    – Zanna
    Dec 30 '18 at 19:22












  • @steeldriver Zanna "data directory" are the directory of my prog1 python. what i do to add a information you need to clear my question?
    – abu-ahmed al-khatiri
    yesterday










  • @abu-ahmedal-khatiri please add the error messages that you get when you try to run prog1 (note not PROG1 - Linux is case-sensitive)
    – steeldriver
    yesterday










  • prog1 --address --port successfully running but it need to reading my prog1 python directory as /usr/local/lib/python2.7/dist-packages/prog1, well i need to make a portable environments @steeldriver
    – abu-ahmed al-khatiri
    yesterday








3




3




"data directory" meaning what exactly? /usr/local/bin should already be in the default PATH and python should search /usr/local/lib/python2.7/dist-packages for modules by default - what exactly doesn't work if you simply type prog1?
– steeldriver
Dec 29 '18 at 18:13




"data directory" meaning what exactly? /usr/local/bin should already be in the default PATH and python should search /usr/local/lib/python2.7/dist-packages for modules by default - what exactly doesn't work if you simply type prog1?
– steeldriver
Dec 29 '18 at 18:13




1




1




This is an XY problem as suggested by steeldriver's comment. Voting to close as unclear
– Zanna
Dec 30 '18 at 19:22






This is an XY problem as suggested by steeldriver's comment. Voting to close as unclear
– Zanna
Dec 30 '18 at 19:22














@steeldriver Zanna "data directory" are the directory of my prog1 python. what i do to add a information you need to clear my question?
– abu-ahmed al-khatiri
yesterday




@steeldriver Zanna "data directory" are the directory of my prog1 python. what i do to add a information you need to clear my question?
– abu-ahmed al-khatiri
yesterday












@abu-ahmedal-khatiri please add the error messages that you get when you try to run prog1 (note not PROG1 - Linux is case-sensitive)
– steeldriver
yesterday




@abu-ahmedal-khatiri please add the error messages that you get when you try to run prog1 (note not PROG1 - Linux is case-sensitive)
– steeldriver
yesterday












prog1 --address --port successfully running but it need to reading my prog1 python directory as /usr/local/lib/python2.7/dist-packages/prog1, well i need to make a portable environments @steeldriver
– abu-ahmed al-khatiri
yesterday




prog1 --address --port successfully running but it need to reading my prog1 python directory as /usr/local/lib/python2.7/dist-packages/prog1, well i need to make a portable environments @steeldriver
– abu-ahmed al-khatiri
yesterday










1 Answer
1






active

oldest

votes


















0














Command names are case-sensitive, like filenames. Run prog1, not PROG1.



But for the record, I'm confused about everything else in your question.






share|improve this answer





















  • PROG1 is the variable OP assigned the path of prog1 to. Perhaps they are trying to run it without typing the full path. But as steeldriver mentioned, the executable seems to be in PATH, so running prog1 should work (but not for the reason you are suggesting!)
    – Zanna
    Dec 30 '18 at 19:24










  • @Zanna $PROG1 is a colon-delimited list of paths (actually the same path twice). I assume it's an environment variable used by prog1, like PYTHONPATH is used by python. But ultimately the question's not clear enough.
    – wjandrea
    Dec 31 '18 at 14:15












  • @wjandrea when i call PROG1 ,it's should be call PYTHONPATH and main folder of prog1. what i do to add a information you need to clear my question?
    – abu-ahmed al-khatiri
    yesterday




















1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









0














Command names are case-sensitive, like filenames. Run prog1, not PROG1.



But for the record, I'm confused about everything else in your question.






share|improve this answer





















  • PROG1 is the variable OP assigned the path of prog1 to. Perhaps they are trying to run it without typing the full path. But as steeldriver mentioned, the executable seems to be in PATH, so running prog1 should work (but not for the reason you are suggesting!)
    – Zanna
    Dec 30 '18 at 19:24










  • @Zanna $PROG1 is a colon-delimited list of paths (actually the same path twice). I assume it's an environment variable used by prog1, like PYTHONPATH is used by python. But ultimately the question's not clear enough.
    – wjandrea
    Dec 31 '18 at 14:15












  • @wjandrea when i call PROG1 ,it's should be call PYTHONPATH and main folder of prog1. what i do to add a information you need to clear my question?
    – abu-ahmed al-khatiri
    yesterday


















0














Command names are case-sensitive, like filenames. Run prog1, not PROG1.



But for the record, I'm confused about everything else in your question.






share|improve this answer





















  • PROG1 is the variable OP assigned the path of prog1 to. Perhaps they are trying to run it without typing the full path. But as steeldriver mentioned, the executable seems to be in PATH, so running prog1 should work (but not for the reason you are suggesting!)
    – Zanna
    Dec 30 '18 at 19:24










  • @Zanna $PROG1 is a colon-delimited list of paths (actually the same path twice). I assume it's an environment variable used by prog1, like PYTHONPATH is used by python. But ultimately the question's not clear enough.
    – wjandrea
    Dec 31 '18 at 14:15












  • @wjandrea when i call PROG1 ,it's should be call PYTHONPATH and main folder of prog1. what i do to add a information you need to clear my question?
    – abu-ahmed al-khatiri
    yesterday
















0












0








0






Command names are case-sensitive, like filenames. Run prog1, not PROG1.



But for the record, I'm confused about everything else in your question.






share|improve this answer












Command names are case-sensitive, like filenames. Run prog1, not PROG1.



But for the record, I'm confused about everything else in your question.







share|improve this answer












share|improve this answer



share|improve this answer










answered Dec 29 '18 at 18:27









wjandrea

8,43342259




8,43342259












  • PROG1 is the variable OP assigned the path of prog1 to. Perhaps they are trying to run it without typing the full path. But as steeldriver mentioned, the executable seems to be in PATH, so running prog1 should work (but not for the reason you are suggesting!)
    – Zanna
    Dec 30 '18 at 19:24










  • @Zanna $PROG1 is a colon-delimited list of paths (actually the same path twice). I assume it's an environment variable used by prog1, like PYTHONPATH is used by python. But ultimately the question's not clear enough.
    – wjandrea
    Dec 31 '18 at 14:15












  • @wjandrea when i call PROG1 ,it's should be call PYTHONPATH and main folder of prog1. what i do to add a information you need to clear my question?
    – abu-ahmed al-khatiri
    yesterday




















  • PROG1 is the variable OP assigned the path of prog1 to. Perhaps they are trying to run it without typing the full path. But as steeldriver mentioned, the executable seems to be in PATH, so running prog1 should work (but not for the reason you are suggesting!)
    – Zanna
    Dec 30 '18 at 19:24










  • @Zanna $PROG1 is a colon-delimited list of paths (actually the same path twice). I assume it's an environment variable used by prog1, like PYTHONPATH is used by python. But ultimately the question's not clear enough.
    – wjandrea
    Dec 31 '18 at 14:15












  • @wjandrea when i call PROG1 ,it's should be call PYTHONPATH and main folder of prog1. what i do to add a information you need to clear my question?
    – abu-ahmed al-khatiri
    yesterday


















PROG1 is the variable OP assigned the path of prog1 to. Perhaps they are trying to run it without typing the full path. But as steeldriver mentioned, the executable seems to be in PATH, so running prog1 should work (but not for the reason you are suggesting!)
– Zanna
Dec 30 '18 at 19:24




PROG1 is the variable OP assigned the path of prog1 to. Perhaps they are trying to run it without typing the full path. But as steeldriver mentioned, the executable seems to be in PATH, so running prog1 should work (but not for the reason you are suggesting!)
– Zanna
Dec 30 '18 at 19:24












@Zanna $PROG1 is a colon-delimited list of paths (actually the same path twice). I assume it's an environment variable used by prog1, like PYTHONPATH is used by python. But ultimately the question's not clear enough.
– wjandrea
Dec 31 '18 at 14:15






@Zanna $PROG1 is a colon-delimited list of paths (actually the same path twice). I assume it's an environment variable used by prog1, like PYTHONPATH is used by python. But ultimately the question's not clear enough.
– wjandrea
Dec 31 '18 at 14:15














@wjandrea when i call PROG1 ,it's should be call PYTHONPATH and main folder of prog1. what i do to add a information you need to clear my question?
– abu-ahmed al-khatiri
yesterday






@wjandrea when i call PROG1 ,it's should be call PYTHONPATH and main folder of prog1. what i do to add a information you need to clear my question?
– abu-ahmed al-khatiri
yesterday





Popular posts from this blog

Human spaceflight

Can not write log (Is /dev/pts mounted?) - openpty in Ubuntu-on-Windows?

File:DeusFollowingSea.jpg