You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is a how-to guide on using VS Code for working with your BEC plugin.
13
+
14
+
## Prerequisites
15
+
16
+
- You have write access to your beamline plugin directory, for example `/sls/<xname>/config/bec/production/<plugin_name>`.
17
+
- If you don't have write access, you can still use VS Code to create and edit files outside of the deployment but you cannot modify the plugin repository directly.
18
+
19
+
## Open VS Code in the correct folder
20
+
21
+
Opening the correct folder is important for VS Code to work well. We highly recommend opening the deployment directory:
22
+
23
+
/// tab | Template
24
+
```bash
25
+
cd /sls/<xname>/config/bec/<deployment_name>
26
+
code .
27
+
```
28
+
///
29
+
30
+
/// tab | Example
31
+
```bash
32
+
cd /sls/x01da/config/bec/production
33
+
code .
34
+
```
35
+
///
36
+
37
+
This ensures that VS Code finds the already prepared settings.json file with the correct Python environment.
This will give you access to Python language support, formatters, linters but also H5Web for previewing HDF5 files.
53
+
54
+
55
+
## Common Pitfalls
56
+
57
+
- If Python syntax highlighting and auto-completion are not working, check that you have the Python extension installed and that the correct directory is open.
58
+
- If you cannot edit files in the deployment, check that you have write access to the deployment directory. Experiment accounts usually do not have write access to the production deployment, so you may need to log in with your personal account.
59
+
60
+
## Next Steps
61
+
62
+
- Continue with [Add Changes to Your Plugin](../git/add-changes-to-plugin-repository.md) if you
63
+
want to commit and push your changes.
64
+
65
+
!!! success "Congratulations!"
66
+
You have successfully set up VS Code for working with your BEC plugin.
0 commit comments