Changes for page Working with HDC Project Files in the Command Line Interface
Last modified by Dennis Segebarth on 2024/10/02 18:38
Summary
-
Page properties (1 modified, 0 added, 0 removed)
Details
- Page properties
-
- Content
-
... ... @@ -1,7 +5,3 @@ 1 -{{box cssClass="floatinginfobox" title="Table of Contents"}} 2 -{{toc/}} 3 -{{/box}} 4 - 5 5 The Pilot Command Line Interface (pilotcli) is a binary executable program that provides a convenient way for users to perform file actions and platform-related tasks programmatically. The Pilot Command Line Interface can be downloaded and run on on your local Linux and Linux subsystems (as Windows user, see for instance the [[Windows Subsystem for Linux installation guide>>url:https://learn.microsoft.com/en-us/windows/wsl/install]]) to support large file uploads. For convenience, pilotcli is also pre-deployed and installed in the users JupyterHub accessible via worskpace tools. 6 6 7 7 = Data Stewardship = ... ... @@ -700,196 +700,17 @@ 700 700 File has been downloaded successfully and saved to: /home/uname/Downloads/sample_file2 701 701 {{/code}} 702 702 703 -Download multiple files or folders as a compressed zip by simply providing all source files or folders and adding the {{code}}--zip{{/code}}option:699 +Download multiple files or folders as a compressed zip by simply providing all source files or folders and adding the ~-~-zip option: 704 704 705 -{{code language="none"}} 706 -$ pilotcli file sync cli/admin/sample_file2 cli/admin/sample_file7 -z core ~/Downloads/ --zip 707 -Preparing downloading 708 -Preparing status: READY_FOR_DOWNLOADING 709 -start downloading... 710 -Downloading cli_1632340658.768384.zip |██████████████████████████████ 100% 00:00 711 -File has been downloaded successfully and saved to: /home/uname/Downloads/cli_1632340658.768384.zip 712 -{{/code}} 713 713 714 - Download files or folders by their geid, instead of their location. To enable this, add {{code}}-i{{/code}} or {{code}}--geid{{/code}} to the command:702 +---- 715 715 716 -{{code language="none"}} 717 -$ pilotcli file sync -i 6d89afd4-f86e-4df7-b6c5-01a9af4e828e-1627499957 7e8e2bac-97c6-4738-bc08-12139c9ba225-1627498854 ~/Downloads/ 718 -Preparing status: READY_FOR_DOWNLOADING 719 -start downloading... 720 -Downloading sample_file7 |██████████████████████████████ 100% 00:00 721 -File has been downloaded successfully and saved to: /home/uname/Downloads/sample_file7 722 -Preparing status: READY_FOR_DOWNLOADING 723 -start downloading... 724 -Downloading sample_file2 |██████████████████████████████ 100% 00:00 725 -File has been downloaded successfully and saved to: /home/uname/Downloads/sample_file2 726 -{{/code}} 704 +- 705 +{{code language="none"}}{{/code}} 727 727 728 -Download a file or folder from the Green Room of a Project. This will only be possible if pilotcli is used within the Platform, e.g. in one of the Workspace tools. It works the same way as downloading from Core, including all the additional options like zipping, by either adding {{code}}-z greenroom{{/code}} or by omitting the {{code}}-z{{/code}} option entirely, as “greenroom” is the default value: 729 - 730 -{{code language="none"}} 731 -$ pilotcli file sync cli/admin/sample_file2 cli/admin/sample_file7 ~/Downloads 732 -Preparing status: READY_FOR_DOWNLOADING 733 -/home/uname/Downloads/sample_file2 already exist, file will be saved as /home/uname/Downloads/sample_file2 (1) 734 -start downloading... 735 -Downloading sample_file2 (1) |██████████████████████████████ 100% 00:00 736 -File has been downloaded successfully and saved to: /home/uname/Downloads/sample_file2 (1) 737 -Preparing status: READY_FOR_DOWNLOADING 738 -start downloading... 739 -Downloading sample_file7 |██████████████████████████████ 100% 00:00 740 -File has been downloaded successfully and saved to: /home/uname/Downloads/sample_file7 741 -{{/code}} 742 - 743 -= Dataset Commands: pilotcli **dataset** = 744 - 745 -== Help == 746 - 747 -{{code language="none"}} 748 -$ pilotcli dataset --help 749 -Usage: pilotcli dataset [OPTIONS] COMMAND [ARGS]... 750 - 751 -Options: 752 - --help Show this message and exit. 753 - 754 -Commands: 755 - download Download a dataset or a particular version of a dataset. 756 - list List datasets belonging to logged in user. 757 - show-detail Show details of a dataset. 758 -{{/code}} 759 - 760 -== Command: **list** == 761 - 762 -* **Usage**: List all datasets for the logged in user 763 -* ((( 764 -**Prerequisite**: 765 - 766 -* User login is required, otherwise an error is returned: "The current login session is invalid. Please login to continue." 767 -))) 768 - 769 -{{code language="none"}} 770 -$ pilotcli dataset list --help 771 -Usage: pilotcli dataset list [OPTIONS] 772 - 773 - List datasets belonging to logged in user. 774 - 775 -Options: 776 - --page INTEGER The page to be listed [default: 0] 777 - --page-size INTEGER number of objects per page [default: 10] 778 - -d, --detached whether run in detached mode 779 - --help Show this message and exit. 780 -{{/code}} 781 - 782 -=== Examples === 783 - 784 -List all datasets that are accessible for the user: 785 - 786 -{{code language="none"}} 787 -$ pilotcli dataset list 788 - Dataset Title Dataset Code 789 ---------------------------------------------------------------------------- 790 - dataset2 aug24202102 791 - dataset-01 aug242021 792 -Page: 0, Number of datasets: 2 793 -{{/code}} 794 - 795 -== Command: **show-detail** == 796 - 797 -* **Usage**: Show the detailed information of a dataset. 798 -* ((( 799 -**Prerequisite**: 800 - 801 -* User login is required, otherwise an error is returned: "The current login session is invalid. Please login to continue." 802 -))) 803 - 804 -{{code language="none"}} 805 -$ pilotcli dataset show-detail --help 806 -Usage: pilotcli dataset show-detail [OPTIONS] CODE 807 - 808 - Show details of a dataset. 809 - 810 -Options: 811 - --page INTEGER The page to be listed [default: 0] 812 - --page-size INTEGER number of objects per page [default: 10] 813 - -d, --detached whether run in detached mode 814 - --help Show this message and exit. 815 -{{/code}} 816 - 817 -=== Examples === 818 - 819 -Show the details of the specified Dataset by providing the unique Dataset Code - “aug242021” in this case: 820 - 821 -{{code language="none"}} 822 -$ pilotcli dataset show-detail aug242021 823 --------------------------------------------------------------------------------- 824 -| Title | dataset-01 | 825 --------------------------------------------------------------------------------- 826 -| Code | aug242021 | 827 --------------------------------------------------------------------------------- 828 -| Authors | uname, cli | 829 --------------------------------------------------------------------------------- 830 -| Type | GENERAL | 831 --------------------------------------------------------------------------------- 832 -| Modality | neuroimaging, microscopy, histological approach | 833 --------------------------------------------------------------------------------- 834 -| Collection_method | import, test, upload | 835 --------------------------------------------------------------------------------- 836 -| Tags | tag1, tag2, tag3 | 837 --------------------------------------------------------------------------------- 838 -| Versions | 1.0, 1.1, 1.2 | 839 --------------------------------------------------------------------------------- 840 -{{/code}} 841 - 842 -== Command: **download** == 843 - 844 -* **Usage**: Download a particular version of a dataset. 845 -* **Options**: -v ~-~-version 846 -* ((( 847 -**Prerequisite**: 848 - 849 -* User login is required, otherwise error is returned: "The current login session is invalid. Please login to continue." 850 -))) 851 - 852 -{{code language="none"}} 853 -$ pilotcli dataset download --help 854 -Usage: pilotcli dataset download [OPTIONS] [CODE]... OUTPUT_PATH 855 - 856 - Download a dataset or a particular version of a dataset. 857 - 858 -Options: 859 - -v, --version TEXT Download a particular version of a dataset. 860 - --help Show this message and exit. 861 -{{/code}} 862 - 863 - 864 -=== Examples === 865 - 866 -Download a Dataset with Code “aug242021”: 867 - 868 -{{code language="none"}} 869 -$ pilotcli dataset download aug242021 ~/Downloads/ 870 -Pre downloading dataset 871 -Preparing status: READY_FOR_DOWNLOADING 872 -start downloading... 873 -Downloading aug242021_1632342868.882398.zip |██████████████████████████████ 100% 00:00 874 -File has been downloaded successfully and saved to: /home/uname/Downloads/aug242021_163234 875 -2868.882398.zip 876 -{{/code}} 877 - 878 -Download the version 1.1 of a Dataset with Code “aug242021”: 879 - 880 -{{code language="none"}} 881 -$ pilotcli dataset download aug242021 ~/Downloads/ -v 1.1 882 -Current dataset version: 1.1 883 -Pre downloading dataset 884 -start downloading... 885 -Downloading aug242021_2021-08-24 11:10:00.042277.zip |██████████████████████████████ 100% 00:00 886 -File has been downloaded successfully and saved to: /home/uname/Downloads/aug242021_2021-08-24 11:10:00.042277.zip 887 -{{/code}} 888 - 889 - 890 - 891 891 ---- 892 892 893 893 Copyright © 2023 [[Indoc Research>>url:https://www.indocresearch.org/]]. 894 894 895 -HealthDataCloud is powered by Pilot technology, a product of [[Indoc Research>>url:https://www.indocresearch.org/]]. 711 +HealthDataCloud is powered by Pilot technology, a product of [[Indoc Research>>url:https://www.indocresearch.org/]].{{/code}} 712 +