Skip to content

Commit

Permalink
frontend/*: move to artiq.frontend, make entry_points
Browse files Browse the repository at this point in the history
* solves the trouble of having to setup PATH and PYTHONPATH in a project
  specific way and keep them changing
* works well with virtualenvs
* works under windows where the shebang is meaningless
* works if your python is not named "python3"

* can use "pip3 install --user --editable ."
  * creates an egg-link in ~/.local/share/... pointing to $PWD
  * generates the scripts and copies them to ~/.local/bin which is likely
    already in your $PATH
  * analogously under windows

* or call scripts as "python3 -m artiq.frontend.master"
jordens authored and sbourdeauducq committed Jan 17, 2015
1 parent 0dc6477 commit 6cc3a9d
Showing 11 changed files with 13 additions and 1 deletion.
Empty file added artiq/frontend/__init__.py
Empty file.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
14 changes: 13 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
@@ -26,5 +26,17 @@
(os.path.join("artiq", "gui"),
[os.path.join("artiq", "gui", "icon.png")])],
ext_modules=[],
scripts=glob(os.path.join("frontend", "*.py"))
entry_points={
"console_scripts": [
"artiq_client=artiq.frontend.client:main",
"artiq_ctlid=artiq.frontend.ctlid:main",
"artiq_gui=artiq.frontend.gui:main",
"artiq_master=artiq.frontend.master:main",
"artiq_run=artiq.frontend.run:main",
"lda_client=artiq.frontend.lda_client:main",
"lda_controller=artiq.frontend.lda_controller:main",
"pdq2_client=artiq.frontend.pdq2_client:main",
"pdq2_controller=artiq.frontend.pdq2_controller:main",
],
}
)

0 comments on commit 6cc3a9d

Please sign in to comment.