-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allow specifying a branch to switch to when setting up a dev environm…
…ent from the wheels (#1406) **Context:** Switching to a different branch after setting up the dev wheel environment would break the latter. **Description of the Change:** Accept a branch to switch to as an optional argument, and switch to it before hard-linking the frontend source code files. **Benefits:** Start working directly on an existing branch. **Possible Drawbacks:** Switching to another branch using git would keep breaking the installation.
- Loading branch information
1 parent
b741618
commit b46f05b
Showing
3 changed files
with
22 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -481,6 +481,12 @@ If you require the Catalyst repository with all its submodules, clone it this wa | |
git clone --recurse-submodules --shallow-submodules [email protected]:PennyLaneAI/catalyst.git | ||
If you need to work on an existing branch, provide its name as a second argument: | ||
|
||
.. code-block:: console | ||
bash ./setup_dev_from_wheel.sh /path/to/virtual/env branch-name | ||
How Does it Work? | ||
^^^^^^^^^^^^^^^^^ | ||
|
||
|
@@ -495,8 +501,7 @@ using the installed Catalyst wheel libraries, hence avoiding compilation. | |
Further Steps | ||
^^^^^^^^^^^^^ | ||
|
||
If everything goes well, ``git status`` should not report any changed files. | ||
|
||
``git status`` should not report any changed files when a branch name is not specified. | ||
Before making changes to the frontend, make sure you create a new branch: | ||
|
||
.. code-block:: console | ||
|
@@ -505,6 +510,9 @@ Before making changes to the frontend, make sure you create a new branch: | |
Once in the new branch, make the wanted changes. Use the IDE of your preference. | ||
|
||
When specifying a branch to switch to, ``git status`` might report changes in some files. | ||
This is normal. Proceed to make changes in the selected branch. | ||
|
||
You can test the changes by executing your sample code under the same virtual environment you used | ||
with the scripts. As files in the repository are hard-linked to the Wheel code, you are actually | ||
changing the code stored at the Python ``site-packages`` folder as well, and you will be automatically | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters