|
22 | 22 |
|
23 | 23 | The CLI and the Python package can be used simultaneously.
|
24 | 24 |
|
25 |
| - ****************** |
26 |
| - {{ app_name }} CLI |
27 |
| - ****************** |
28 |
| - |
29 |
| - The {{ app_name }} CLI can be installed on Linux, macOS, and Windows through a terminal |
30 |
| - or shell prompt: |
31 |
| - |
32 |
| - .. tab-set:: |
33 |
| - |
34 |
| - .. tab-item:: Linux/macOS |
35 |
| - |
36 |
| - Open a terminal, paste the command shown below and press enter. |
37 |
| - |
38 |
| - .. code-block:: bash |
39 |
| -
|
40 |
| - (touch tmp.sh && curl -fsSL https://raw.githubusercontent.com/hpcflow/install-scripts/main/src/install-{{ app_package_name }}.sh > tmp.sh && bash tmp.sh --prerelease --path --univlink) ; rm tmp.sh |
41 |
| -
|
42 |
| - .. tab-item:: Windows |
43 |
| - |
44 |
| - Open a Powershell terminal, paste the command shown below and press enter. |
45 |
| - |
46 |
| - .. code-block:: powershell |
47 |
| -
|
48 |
| - & $([scriptblock]::Create((New-Object Net.WebClient).DownloadString('https://raw.githubusercontent.com/hpcflow/install-scripts/main/src/install-{{ app_package_name }}.ps1'))) -PreRelease -UnivLink |
49 |
| -
|
50 |
| - .. admonition:: What does this script do? |
51 |
| - :class: note dropdown |
52 |
| - |
53 |
| - The above command downloads a script from the {{ app_name }} GitHub repository and runs it. The script does the following: |
54 |
| - |
55 |
| - #. It downloads the latest prerelease version of {{ app_name }} zip archived in a single folder. |
56 |
| - #. The archive is extracted and the folder placed in an accessible location. The location depends on the operating system. In Linux it is ``/.local/share/{{ app_package_name }}``. In macOS it is ``~/Library/Application Support/{{ app_package_name }}``. In Windows it is ``Username\AppData\Local\{{ app_package_name }}``. |
57 |
| - #. A symbolic link (Linux/macOS) or an alias pointing to the file is created. This allows {{ app_name }} to be run by entering a simple command. |
58 |
| - #. A command is added to ``.bashrc``/``.zshrc`` (linux/macOS) or the Powershell profile (Windows) that allows {{ app_name }} to be run from any folder. |
59 |
| - |
60 |
| - If the script detects that the version of {{ app_name }} it is trying to install is already there, it will stop |
61 |
| - running and exit. |
62 |
| - |
63 |
| - |
64 |
| - |
65 |
| - .. hint:: |
66 |
| - |
67 |
| - If you are installing {{ app_name }} on an HPC resource, check that you can connect |
68 |
| - to the internet first. You might need to load a proxy module, for example. |
69 |
| - |
70 |
| - .. _def_python_versions: |
71 |
| - |
72 |
| - ***************************** |
73 |
| - {{ app_name }} Python package |
74 |
| - ***************************** |
75 |
| - |
76 |
| - {{ app_name }} is compatible with Python versions {{ supported_python }}. |
77 |
| - |
78 | 25 | Using pip
|
79 | 26 | ==========================
|
80 | 27 |
|
81 |
| - Use pip to install the Python package from PyPI:: |
82 |
| - |
83 |
| - pip install {{ dist_name }}=="{{ app_version }}" |
| 28 | + The recommended way to install {{ app_name }} is to |
| 29 | + use pip to install the Python package from PyPI:: |
84 | 30 |
|
85 |
| - Using conda |
86 |
| - =========== |
| 31 | + pip install {{ dist_name }} |
87 | 32 |
|
88 |
| - Coming soon! |
89 |
| - |
90 |
| - ******************************** |
91 |
| - Download CLI binaries (advanced) |
92 |
| - ******************************** |
93 |
| - |
94 |
| - Binaries are available in two formats, corresponding to the two different formats that |
95 |
| - PyInstaller `can generate <https://pyinstaller.org/en/stable/usage.html#what-to-generate>`_: |
96 |
| - |
97 |
| - * A single executable file containing everything. |
98 |
| - * A folder containing an executable and supporting files. |
99 |
| - |
100 |
| - Click below to download the {{ app_name }} binary for your platform: |
101 |
| - |
102 |
| - .. raw:: html |
103 |
| - |
104 |
| - {{ download_links_table_html }} |
| 33 | + This installs the python package, which also gives the CLI version of {{ app_name }}. |
105 | 34 |
|
106 | 35 | *************
|
107 | 36 | Release notes
|
108 | 37 | *************
|
109 | 38 |
|
110 | 39 | Release notes for this version ({{app_version}}) are `available on GitHub <https://github.com/{{ github_user }}/{{ github_repo }}/releases/tag/v{{ app_version }}>`_.
|
111 | 40 | Use the version switcher in the top-right corner of the page to download/install other versions.
|
| 41 | + |
| 42 | + Alternative installation methods |
| 43 | + ================================ |
| 44 | + Although *not currently recommended*, |
| 45 | + advanced users may wish to use one of the :ref:`alternative installation methods <alternative_install>`. |
| 46 | + |
| 47 | + |
| 48 | + ############# |
| 49 | + Configuration |
| 50 | + ############# |
| 51 | + |
| 52 | + {{ app_name }} uses a config file to control details of how it executes workflows. |
| 53 | + A :ref:`default config file <default_config>` will be created the first time you submit a workflow. |
| 54 | + This will work without modification on a personal machine, |
| 55 | + however if you are using {{ app_name }} on HPC you will likely need to make some |
| 56 | + modifications to describe the job scheduler, and settings for multiple cores, |
| 57 | + and to point to your {{ app_name }} environments file. |
| 58 | + |
| 59 | + `Some examples <https://github.com/hpcflow/matflow-configs>`_ are given |
| 60 | + for the University of Manchester's CSF. |
| 61 | + |
| 62 | + The path to your config file can be found using ``{{ app_module }} manage get-config-path``, |
| 63 | + or to open the config file directly, use ``{{ app_module }} open config``. |
| 64 | + |
| 65 | + ############# |
| 66 | + Environments |
| 67 | + ############# |
| 68 | + |
| 69 | + {{ app_name }} has the concept of environments, similar to python virtual environments. |
| 70 | + These are required so that tasks can run using the specific software they require. |
| 71 | + Your {{ app_name }} environments must be defined in your environments (YAML) file before {{ app_name }} |
| 72 | + can run workflows, and this environment file must be pointed to in the config file |
| 73 | + via the ``environment_sources`` key. |
| 74 | + Once this has been done, your environment file can be be opened using ``{{ app_module }} open env-source``. |
| 75 | + |
| 76 | + Below is an example environments file that defines an environment for running Pyton scripts. |
| 77 | + Domain-specific tools can be added to the environments file as required, each with their own |
| 78 | + setup instructions for loading that tool on your machine. |
| 79 | + |
| 80 | + .. code-block:: yaml |
| 81 | +
|
| 82 | + - name: python_env |
| 83 | + executables: |
| 84 | + - label: python_script |
| 85 | + instances: |
| 86 | + - command: python "<<script_path>>" <<args>> |
| 87 | + num_cores: |
| 88 | + start: 1 |
| 89 | + stop: 32 |
| 90 | + parallel_mode: null |
0 commit comments