@sussex-occ/sid-provider-client v1.2.21
SID Provider Client
This project contains a command line tool sid-provider that can be used by a SID provider organisation to submit data into SID.
In its current incarnation, it 'wraps' the existing pseudocmd tool so, after pre-processing the data files, it will use the pseudo tool to upload the data to SID in the usual way. This means that it expects the existing psedocmd tool to already be installed in the default location c:\beautifulinformation\pseudoapp.
Installation
You must have node.js version 20 or above installed on your machine before starting the installation. We use node package manager (npm) to make software installation and update easy and error free. npm is installed as part of the node.js installation.
Installations use the -g flag to install the software globally for the current user.
Installation on Windows
> npm install @sussex-occ/sid-provider-client -g
After installation, you may need to add the folder c:\Users\\AppData\Roaming\npm to the system path if the sid-provider command is not recognised. Also, as the script is unsigned, you may need to issue the following command to allow an unsigned script to be run:
> Set-ExecutionPolicy -Scope CurrentUser -ExecutionPolicy RemoteSigned
Installation on Macos, Linux or Unix systems
> npm install @sussex-occ/sid-provider-client -g
On UNIX based systems, the PATH variable will be set automatically to pick up the sid-provider command.
Usage
> sid-provider help
This will list all the sub-commands available and how to use them.
Run environment checks
Utility to check the environment to ensure that the required connectivity to the SID back end is in place. If the checks don't pass then the tool is unlikely to work properly.
> sid-provider check
Activate the tool
One off script to set up the tool before it is used for the first time.
> sid-provider activate
You will to enter a one-off activation code before you can complete this step.
Upload data to SID.
The main script to upload data to SID. There are many options available, and use of these options will depend upon your environment. Use the help command to view the options:
> sid-provider help upload
Examples would be:
> sid-provider upload -usr XYZ -pwd secret -dom Live -fil "*.csv"
> sid-provider upload -usr XYZ -pwd secret -dom Live -fil "*.csv" -dir "c:\exported_data\sid\data"
If you have previously used the pseudocmd.exe tool, you should be able to supply the same arguments to the new tool. There is just one important difference. The pseudocmd.exe tool expected a : to separate each command option form its value. The new tool expects a space, for example, the space between -usr and XYZ as shown above.
Development
git clone https://github.com/Sussex-OCC/sid-import-tools.git
cd sid-import-tools
npm i
npm run dev
This starts esbuild in watch mode that compiles the typescript into the /dist folder. Every time a source file is updated, esbuild will automatically re-compile.
To publish the package to Node Package Manager (npm), update the version field in package.json, then issue the following command:
npm run release
4 months ago
4 months ago
3 months ago
3 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
5 months ago
5 months ago
5 months ago
5 months ago
5 months ago
5 months ago
5 months ago
5 months ago
5 months ago
6 months ago
6 months ago
6 months ago
6 months ago
6 months ago