diff --git a/README.md b/README.md index 2759b4fbed2d9a64ba07ddc0b9b7ff070f6738b9..4ddbc892dd73b648024090b3f366cf0e03b798ee 100644 --- a/README.md +++ b/README.md @@ -1,42 +1,10 @@ -# LabKey Scripts +# ๐งฉ LabKey Python Scripts -This repository contains Python scripts that perform various tasks using the LabKey Python API. These scripts help interact with LabKey Server for data retrieval, updates, and management tasks. +## ๐ Project Management Scripts +This directory includes Python scripts that leverage the LabKey Python API to perform project management tasks, requiring Site Admin privileges. -## Requirements -- Python 3.x -- `labkey` Python package -- `.netrc` file for authentication (https://www.labkey.org/Documentation/wiki-page.view?name=netrc) - - -## Scripts Overview - -### 1. Create_Project.py -- Creates a new project in LabKey. -- Takes a **project name** as a command-line argument. -- If the project already exists, it notifies the user. - -**Usage:** -```bash -python Create_Project.py <project_name> -``` - -### 2. Create_Project_and_subfolder.py -- Creates a project and a **Sample Manager** type subfolder in LabKey. -- Takes both a **project name** and a **subfolder name** as arguments. - -**Usage:** -```bash -python Create_Project_and_subfolder.py <project_name> <subfolder_name> -``` - -### 3. Get_projects_list.py -- Connects to the LabKey server using credentials stored in a `.netrc` file. -- Retrieves a list of projects and folders. - -**Usage:** -```bash -python Get_projects_list.py -``` +## ๐งช Sample Manager Automation Scripts +This directory contains a Python script that automates the creation and population of projects, studies, patients, samples, and storage hierarchies in LabKey Sample Manager using structured data from Excel files. ## Contributing Feel free to submit pull requests for enhancements or bug fixes. Ensure that your code follows best practices and includes comments where necessary. @@ -45,5 +13,4 @@ Feel free to submit pull requests for enhancements or bug fixes. Ensure that you This project is licensed under the MIT License. ## Contact -For questions or issues, reach out to scicore-admin@unibas.ch. - +For questions or issues, reach out to scicore-admin@unibas.ch. \ No newline at end of file diff --git a/Create_Project.py b/Site_Admin_Scripts/Create_Project.py similarity index 100% rename from Create_Project.py rename to Site_Admin_Scripts/Create_Project.py diff --git a/Create_Project_and_subfolder.py b/Site_Admin_Scripts/Create_Project_and_subfolder.py similarity index 100% rename from Create_Project_and_subfolder.py rename to Site_Admin_Scripts/Create_Project_and_subfolder.py diff --git a/Get_projects_list.py b/Site_Admin_Scripts/Get_projects_list.py similarity index 100% rename from Get_projects_list.py rename to Site_Admin_Scripts/Get_projects_list.py diff --git a/Site_Admin_Scripts/README.md b/Site_Admin_Scripts/README.md new file mode 100644 index 0000000000000000000000000000000000000000..1fcd492b2fb3f3fafe9b2fab5e6fb548dd255933 --- /dev/null +++ b/Site_Admin_Scripts/README.md @@ -0,0 +1,49 @@ +# LabKey Scripts + +This repository provides Python scripts that leverage the LabKey Python API to streamline Project management on a LabKey Server. These scripts are intended for users with Site Admin privileges and are designed to enhance operational efficiency and server interaction. + +## Requirements +- Python 3.x +- `labkey` Python package +- `.netrc` file for authentication (https://www.labkey.org/Documentation/wiki-page.view?name=netrc) + + +## Scripts Overview + +### 1. Create_Project.py +- Creates a new project in LabKey. +- Takes a **project name** as a command-line argument. +- If the project already exists, it notifies the user. + +**Usage:** +```bash +python Create_Project.py <project_name> +``` + +### 2. Create_Project_and_subfolder.py +- Creates a project and a **Sample Manager** type subfolder in LabKey. +- Takes both a **project name** and a **subfolder name** as arguments. + +**Usage:** +```bash +python Create_Project_and_subfolder.py <project_name> <subfolder_name> +``` + +### 3. Get_projects_list.py +- Connects to the LabKey server using credentials stored in a `.netrc` file. +- Retrieves a list of projects and folders. + +**Usage:** +```bash +python Get_projects_list.py +``` + +## Contributing +Feel free to submit pull requests for enhancements or bug fixes. Ensure that your code follows best practices and includes comments where necessary. + +## License +This project is licensed under the MIT License. + +## Contact +For questions or issues, reach out to scicore-admin@unibas.ch. +