ebuchana
(Emma Buchanan)
August 9, 2023, 4:15pm
1
Hello,
Im sorry if this is a stupid question but I am new to SWAN and usually only code using a linux terminal. The problem I am having is that every time I open SWAN, I do not see any of my projects listed. When I look at my CERNBox I see the projects and code there but i do not see them on the SWAN or understand how to open them using CERNBox. Can anyone point me towards some tutorials on how to open past projects,
Thanks,
Emma
etejedor
(Enric Tejedor Saavedra)
August 10, 2023, 7:57am
2
Dear Emma,
How did you create those projects? Did you create them in SWAN? More precisely, as described here:
# Create a Project
Once your session starts, SWAN will first show the **Projects** view. A _Project_ in SWAN is a special type of folder that you can use as a container for your work on a given topic: notebooks, input/output files, other subfolders, etc. As will be explained later in this help panel, a project is also the unit of sharing in SWAN: you can share a project with your colleagues and thus provide them with everything they need to run the notebooks you created.
From the Projects tab, you can create a folder by clicking on the **`+`** button. You will be then asked a name for the project and, if you do not provide it, a default one will be chosen.
Once the project is successfully created, you will be automatically redirected inside it so that you can start adding content to it.
### Create a Project from git
SWAN also allows you to create a Project from a git repository. In the Projects view, you can click the **`Download Project from git`** button and enter the path to the repository. Please note that you need to append _.git_ to the URL of the repository. For security reasons, only repositories in Github and CERN Gitlab are allowed.
Alternatively, if the git repository has an **`Open in SWAN`** button, you just need to click it and its contents will be copied into a new Project.
#### Protected repositories
The repositories with visibility set to 'Private' or 'Internal' in Gitlab cannot be cloned by simply pasting the repository path. To clone these repositories create a [Project access token ](https://docs.gitlab.com/ee/user/project/settings/project_access_tokens.html) and then modify the repository URL to `https://<username>:<token>@<normal_repo_URL>.git`
When you are in SWAN, what you see is the content of your $CERNBOX_HOME/SWAN_projects
directory, which is where the SWAN projects live. If you want to navigate on folders that are outside of that directory. you can use the CERNBox tab:
# Browse files
The whole content of your CERNBox space is fully accessible from SWAN. If you click on the **`CERNBox`** tab, you will be able to browse your files.
If you click on notebooks, the notebook interface will open to edit them. Similarly, an editor appears when clicking on files with textual formats.
By browsing through your CERNBox, you can create notebooks inside regular folders that do not belong any project, if you wish so. The only drawback is that you will not be able to share those notebooks from SWAN, since projects are the unit of sharing.
If you still have issues finding your folders, please open a ticket here:
https://cern.service-now.com/service-portal/?id=functional_element&name=swan
Best,
Enric