fix setup
This commit is contained in:
parent
d309a0d677
commit
29a8aa136d
38
README.md
38
README.md
|
@ -1,13 +1,17 @@
|
||||||
# d4science_auth_cds
|
# d4science_copernicus_cds
|
||||||
|
|
||||||
**d4science_auth_cds** is a library developed by CNR-ISTI to manage Climate Data Store (CDS) API authentication within D4Science JupyterLab environments. It simplifies credential handling, allowing for secure, reusable access to the CDS API across multiple notebooks.
|
**d4science_copernicus_cds** is a library developed by CNR-ISTI to manage Climate Data Store (CDS) API authentication within D4Science JupyterLab environments. It simplifies credential handling, allowing for secure, reusable access to the CDS API across multiple notebooks.
|
||||||
|
|
||||||
|
## Version
|
||||||
|
|
||||||
|
v.1.0.0
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
Install the library directly from the D4Science Git
|
Install the library directly from the D4Science Git
|
||||||
|
|
||||||
```
|
```
|
||||||
pip install git+https://code-repo.d4science.org/D4Science/d4science_auth_cds.git
|
pip install git+https://code-repo.d4science.org/D4Science/d4science_copernicus_cds.git
|
||||||
```
|
```
|
||||||
|
|
||||||
## Built With
|
## Built With
|
||||||
|
@ -27,25 +31,24 @@ Below are the main commands provided by the auth_cds library to manage CDS API a
|
||||||
|
|
||||||
First, import the necessary functions:
|
First, import the necessary functions:
|
||||||
|
|
||||||
```python from auth_cds import cds_authenticate, cds_remove_conf, cds_save_conf, cds_remove_env, cds_show_conf ```
|
```python
|
||||||
|
from auth_cds import cds_authenticate, cds_remove_conf, cds_save_conf, cds_remove_env, cds_show_conf
|
||||||
|
```
|
||||||
|
|
||||||
Main Commands
|
Main Commands
|
||||||
Authenticate and get CDS client:
|
Authenticate and get CDS client:
|
||||||
This command authenticates and returns a CDS API client instance.
|
This command authenticates and returns a CDS API client instance.
|
||||||
|
|
||||||
```python client = cds_authenticate() ```
|
|
||||||
|
|
||||||
Remove configurations from default paths:
|
|
||||||
Removes any saved configuration files. To execute, remove the comment symbol (#).
|
|
||||||
|
|
||||||
```python
|
```python
|
||||||
cds_remove_conf()
|
client = cds_authenticate()
|
||||||
```
|
```
|
||||||
|
|
||||||
Save the current or new configuration:
|
Save the current or new configuration:
|
||||||
Saves the configuration to a default hidden file.
|
Saves the configuration to a default hidden file.
|
||||||
|
|
||||||
```python cds_save_conf() ```
|
```python
|
||||||
|
cds_save_conf()
|
||||||
|
```
|
||||||
|
|
||||||
Remove environment variables for the CDS API:
|
Remove environment variables for the CDS API:
|
||||||
Clears the CDS API credentials from environment variables. To execute, remove the comment symbol (#).
|
Clears the CDS API credentials from environment variables. To execute, remove the comment symbol (#).
|
||||||
|
@ -54,12 +57,19 @@ Clears the CDS API credentials from environment variables. To execute, remove th
|
||||||
cds_remove_env()
|
cds_remove_env()
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Remove configurations from default paths:
|
||||||
|
Removes any saved configuration files. To execute, remove the comment symbol (#).
|
||||||
|
|
||||||
|
```python
|
||||||
|
cds_remove_conf()
|
||||||
|
```
|
||||||
|
|
||||||
Show current configuration from environment and files:
|
Show current configuration from environment and files:
|
||||||
Displays the credentials configured in the environment and any found in the saved configuration file.
|
Displays the credentials configured in the environment and any found in the saved configuration file.
|
||||||
|
|
||||||
```python cds_show_conf() ```
|
```python
|
||||||
|
cds_show_conf()
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
## Change log
|
## Change log
|
||||||
|
|
|
@ -1,14 +1,14 @@
|
||||||
from setuptools import setup, find_packages
|
from setuptools import setup, find_packages
|
||||||
|
|
||||||
setup(
|
setup(
|
||||||
name="d4science_auth_cds",
|
name="d4science_copernicus_cds",
|
||||||
version="1.0.0",
|
version="1.0.0",
|
||||||
description="A D4Science library for managing CDS API authentication in JupyterLab",
|
description="A D4Science library for managing CDS API authentication in JupyterLab",
|
||||||
long_description=open("README.md").read(),
|
long_description=open("README.md").read(),
|
||||||
long_description_content_type="text/markdown",
|
long_description_content_type="text/markdown",
|
||||||
author="Alfredo Oliviero",
|
author="Alfredo Oliviero",
|
||||||
author_email="alfredo.oliviero@isti.cnr.it",
|
author_email="alfredo.oliviero@isti.cnr.it",
|
||||||
url="https://code-repo.d4science.org/D4Science/d4science_auth_cds.git",
|
url="https://code-repo.d4science.org/D4Science/d4science_copernicus_cds.git",
|
||||||
packages=find_packages(),
|
packages=find_packages(),
|
||||||
install_requires=[
|
install_requires=[
|
||||||
"cdsapi>=0.7.2",
|
"cdsapi>=0.7.2",
|
Loading…
Reference in New Issue