diff --git a/src/nextcloud-artifacts.ts b/src/nextcloud-artifacts.ts index 3a069c7..85bbc71 100644 --- a/src/nextcloud-artifacts.ts +++ b/src/nextcloud-artifacts.ts @@ -1,5 +1,10 @@ import { Inputs } from './Inputs'; import { NextcloudArtifact } from './nextcloud/NextcloudArtifact'; +import * as core from '@actions/core'; -var artifact = new NextcloudArtifact(Inputs.ArtifactName, Inputs.ArtifactPath, Inputs.NoFileBehvaior); -artifact.run(); \ No newline at end of file +try { + var artifact = new NextcloudArtifact(Inputs.ArtifactName, Inputs.ArtifactPath, Inputs.NoFileBehvaior); + artifact.run(); +} catch (error) { + core.setFailed(error.message); +} diff --git a/src/nextcloud/NextcloudClient.ts b/src/nextcloud/NextcloudClient.ts index a335e72..2417088 100644 --- a/src/nextcloud/NextcloudClient.ts +++ b/src/nextcloud/NextcloudClient.ts @@ -37,10 +37,14 @@ export class NextcloudClient { } public async uploadFiles(files: string[]) { + core.info("Begin uploading files..."); const spec = this.uploadSpec(files); + core.info("Zipping files..."); var zip = await this.zipFiles(spec); + core.info("Uploading to Nextcloud..."); const path = await this.upload(zip); + core.info("Sharing file..."); await this.shareFile(path); }