cds-spreadsheetimporter-plugin
Advanced tools
## [1.0.2](https://github.com/lemaiwo/cds-spreadsheetimporter-plugin/compare/v1.0.1...v1.0.2) (2024-11-19) | ||
### Bug Fixes | ||
* add error handling if entity is not available ([516009b](https://github.com/lemaiwo/cds-spreadsheetimporter-plugin/commit/516009b269b34a18ab4496a7447ba887100df0f0)) | ||
## 1.0.1 (2024-11-19) | ||
@@ -4,0 +11,0 @@ |
@@ -12,2 +12,6 @@ const cds = global.cds || require("@sap/cds"); | ||
const entity = cds.entities()[req.params[0].entity]; | ||
if (!entity) { | ||
req.error(400, `Entity '${req.params[0].entity}' not found`); | ||
return; | ||
} | ||
let spreadsheetSheetsData = []; | ||
@@ -14,0 +18,0 @@ let columnNames = []; |
{ | ||
"name": "cds-spreadsheetimporter-plugin", | ||
"version": "1.0.1", | ||
"version": "1.0.2", | ||
"description": "Spreadsheet importer as CAP plugin", | ||
@@ -5,0 +5,0 @@ "main": "cds-plugin.js", |
# cds-spreadsheetimporter-plugin | ||
This is a plugin for the [CAP](https://cap.cloud.sap/) framework that allows you to import data from spreadsheets into your CAP project. | ||
## Release Process | ||
This project uses [release-it](https://github.com/release-it/release-it) to automate version management and package publishing. The release workflow is configured through GitHub Actions and can be triggered in two ways: | ||
### Manual Release | ||
1. Go to the GitHub repository's "Actions" tab | ||
2. Select the "Release" workflow | ||
3. Click "Run workflow" | ||
4. You can either: | ||
- Leave the version field empty for automatic versioning based on conventional commits | ||
- Specify a specific version (e.g., "1.2.0") | ||
### Local Release (for maintainers) | ||
If you prefer to release from your local machine: | ||
1. Ensure you have the necessary credentials: | ||
- `NPM_TOKEN` for publishing to npm | ||
- `GITHUB_TOKEN` for creating GitHub releases | ||
2. Run one of the following commands: | ||
```bash | ||
npm run release # For automatic versioning | ||
npm run release X.Y.Z # For specific version | ||
``` | ||
### What happens during release? | ||
The release process will: | ||
1. Determine the next version number (based on conventional commits or manual input) | ||
2. Update the package.json version | ||
3. Generate/update the CHANGELOG.md file | ||
4. Create a git tag | ||
5. Push changes to GitHub | ||
6. Create a GitHub release with release notes | ||
7. Publish the package to npm | ||
The release configuration uses the Angular conventional commit preset for changelog generation and requires commit messages to follow the conventional commits specification. |
@@ -15,3 +15,3 @@ const fs = require('fs'); | ||
const uploadResponse = await fetch( | ||
`${BASE_URL}/odata/v4/importer/Spreadsheet(entity='Books')/content`, | ||
`${BASE_URL}/odata/v4/importer/Spreadsheet(entity='my.bookshop.Books')/content`, | ||
{ | ||
@@ -18,0 +18,0 @@ method: 'PUT', |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
57345
3.41%720
0.56%44
1000%3
-40%