@skuba-lib/api 2.0.2 → 2.0.3-build-package-patch-2-20260226003820

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/git/index.cjs CHANGED
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
2
  const require_error = require('../error-BEFwIvK2.cjs');
3
- const require_isFileGitIgnored = require('../isFileGitIgnored-86LsBKuU.cjs');
3
+ const require_isFileGitIgnored = require('../isFileGitIgnored-Bwd16lEn.cjs');
4
4
 
5
5
  //#region src/git/index.ts
6
6
  var git_exports = /* @__PURE__ */ require_error.__exportAll({
package/lib/git/index.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  import { n as __exportAll } from "../chunk-DoQ1iNfF.mjs";
2
- import { c as getOwnerAndRepo, d as currentBranch, f as commitAllChanges, h as commit, i as push, l as getHeadCommitId, m as findRoot, n as reset, p as getChangedFiles, r as fastForwardBranch, t as isFileGitIgnored, u as getHeadCommitMessage } from "../isFileGitIgnored-Dv4xauFf.mjs";
2
+ import { c as getOwnerAndRepo, d as currentBranch, f as commitAllChanges, h as commit, i as push, l as getHeadCommitId, m as findRoot, n as reset, p as getChangedFiles, r as fastForwardBranch, t as isFileGitIgnored, u as getHeadCommitMessage } from "../isFileGitIgnored-DsgFRsI5.mjs";
3
3
 
4
4
  //#region src/git/index.ts
5
5
  var git_exports = /* @__PURE__ */ __exportAll({
@@ -1,7 +1,7 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
2
  const require_error = require('../error-BEFwIvK2.cjs');
3
- const require_isFileGitIgnored = require('../isFileGitIgnored-86LsBKuU.cjs');
4
- const require_push = require('../push-DV2iCZE-.cjs');
3
+ const require_isFileGitIgnored = require('../isFileGitIgnored-Bwd16lEn.cjs');
4
+ const require_push = require('../push-DMpMs9CT.cjs');
5
5
 
6
6
  //#region src/github/index.ts
7
7
  var github_exports = /* @__PURE__ */ require_error.__exportAll({
@@ -1,6 +1,6 @@
1
1
  import { n as __exportAll } from "../chunk-DoQ1iNfF.mjs";
2
- import { a as apiTokenFromEnvironment, o as buildNameFromEnvironment, s as enabledFromEnvironment } from "../isFileGitIgnored-Dv4xauFf.mjs";
3
- import { a as getPullRequestNumber, i as putIssueComment, n as uploadAllFileChanges, o as createCheckRun, r as uploadFileChanges, t as readFileChanges } from "../push-hzuiuMpZ.mjs";
2
+ import { a as apiTokenFromEnvironment, o as buildNameFromEnvironment, s as enabledFromEnvironment } from "../isFileGitIgnored-DsgFRsI5.mjs";
3
+ import { a as getPullRequestNumber, i as putIssueComment, n as uploadAllFileChanges, o as createCheckRun, r as uploadFileChanges, t as readFileChanges } from "../push-DfTF3Swx.mjs";
4
4
 
5
5
  //#region src/github/index.ts
6
6
  var github_exports = /* @__PURE__ */ __exportAll({
package/lib/index.cjs CHANGED
@@ -2,9 +2,9 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
2
  require('./exec-CVlcoV9u.cjs');
3
3
  require('./md-fbyvRhpo.cjs');
4
4
  const require_buildkite_index = require('./buildkite/index.cjs');
5
- require('./isFileGitIgnored-86LsBKuU.cjs');
5
+ require('./isFileGitIgnored-Bwd16lEn.cjs');
6
6
  const require_git_index = require('./git/index.cjs');
7
- require('./push-DV2iCZE-.cjs');
7
+ require('./push-DMpMs9CT.cjs');
8
8
  const require_github_index = require('./github/index.cjs');
9
9
  const require_net_index = require('./net/index.cjs');
10
10
 
package/lib/index.mjs CHANGED
@@ -1,9 +1,9 @@
1
1
  import "./exec-Bcan8fLb.mjs";
2
2
  import "./md-CvXERddQ.mjs";
3
3
  import { t as buildkite_exports } from "./buildkite/index.mjs";
4
- import "./isFileGitIgnored-Dv4xauFf.mjs";
4
+ import "./isFileGitIgnored-DsgFRsI5.mjs";
5
5
  import { t as git_exports } from "./git/index.mjs";
6
- import "./push-hzuiuMpZ.mjs";
6
+ import "./push-DfTF3Swx.mjs";
7
7
  import { t as github_exports } from "./github/index.mjs";
8
8
  import { t as net_exports } from "./net/index.mjs";
9
9
 
@@ -207,7 +207,7 @@ const getHeadCommitMessage = async ({ dir, env = process.env }) => {
207
207
  * 1. seek-oss
208
208
  * 2. skuba
209
209
  */
210
- const ownerRepoRegex = /github.com(?::|\/)(.+)\/(.+).git$/;
210
+ const ownerRepoRegex = /github\.com(?::|\/)([a-zA-Z0-9._-]+)\/([a-zA-Z0-9._-]+)\.git$/;
211
211
  const ownerAndRepoFromUrl = (url) => {
212
212
  const match = ownerRepoRegex.exec(url);
213
213
  return {
@@ -202,7 +202,7 @@ const getHeadCommitMessage = async ({ dir, env = process.env }) => {
202
202
  * 1. seek-oss
203
203
  * 2. skuba
204
204
  */
205
- const ownerRepoRegex = /github.com(?::|\/)(.+)\/(.+).git$/;
205
+ const ownerRepoRegex = /github\.com(?::|\/)([a-zA-Z0-9._-]+)\/([a-zA-Z0-9._-]+)\.git$/;
206
206
  const ownerAndRepoFromUrl = (url) => {
207
207
  const match = ownerRepoRegex.exec(url);
208
208
  return {
@@ -1,5 +1,5 @@
1
1
  const require_error = require('./error-BEFwIvK2.cjs');
2
- const require_isFileGitIgnored = require('./isFileGitIgnored-86LsBKuU.cjs');
2
+ const require_isFileGitIgnored = require('./isFileGitIgnored-Bwd16lEn.cjs');
3
3
  let path = require("path");
4
4
  path = require_error.__toESM(path);
5
5
  let fs_extra = require("fs-extra");
@@ -65,7 +65,7 @@ const createCheckRun = async ({ annotations, conclusion, name, summary, text, ti
65
65
  const getPullRequestNumber = async (params = {}) => {
66
66
  const env = params.env ?? process.env;
67
67
  const dir = process.cwd();
68
- const number = Number(env.BUILDKITE_PULL_REQUEST ?? env.GITHUB_REF?.replace(/^refs\/pull\/(\d+).*$/, "$1"));
68
+ const number = Number(env.BUILDKITE_PULL_REQUEST ?? env.GITHUB_REF?.replace(/^refs\/pull\/(\d+)/, "$1"));
69
69
  if (Number.isSafeInteger(number)) return number;
70
70
  const client = params.client ?? await createRestClient({ auth: require_isFileGitIgnored.apiTokenFromEnvironment() });
71
71
  const [commitId, { owner, repo }] = await Promise.all([require_isFileGitIgnored.getHeadCommitId({
@@ -160,6 +160,7 @@ const uploadAllFileChanges = async ({ branch, dir, messageHeadline, ignore, mess
160
160
  });
161
161
  if (!changedFiles.length) return;
162
162
  const fileChanges = await readFileChanges(dir, changedFiles);
163
+ console.dir(fileChanges, { depth: null });
163
164
  const commitId = await uploadFileChanges({
164
165
  dir,
165
166
  branch,
@@ -1,5 +1,5 @@
1
1
  import { r as pluralise } from "./error-DIBTmfX2.mjs";
2
- import { a as apiTokenFromEnvironment, c as getOwnerAndRepo, l as getHeadCommitId, m as findRoot, p as getChangedFiles, r as fastForwardBranch } from "./isFileGitIgnored-Dv4xauFf.mjs";
2
+ import { a as apiTokenFromEnvironment, c as getOwnerAndRepo, l as getHeadCommitId, m as findRoot, p as getChangedFiles, r as fastForwardBranch } from "./isFileGitIgnored-DsgFRsI5.mjs";
3
3
  import path from "path";
4
4
  import fs from "fs-extra";
5
5
 
@@ -63,7 +63,7 @@ const createCheckRun = async ({ annotations, conclusion, name, summary, text, ti
63
63
  const getPullRequestNumber = async (params = {}) => {
64
64
  const env = params.env ?? process.env;
65
65
  const dir = process.cwd();
66
- const number = Number(env.BUILDKITE_PULL_REQUEST ?? env.GITHUB_REF?.replace(/^refs\/pull\/(\d+).*$/, "$1"));
66
+ const number = Number(env.BUILDKITE_PULL_REQUEST ?? env.GITHUB_REF?.replace(/^refs\/pull\/(\d+)/, "$1"));
67
67
  if (Number.isSafeInteger(number)) return number;
68
68
  const client = params.client ?? await createRestClient({ auth: apiTokenFromEnvironment() });
69
69
  const [commitId, { owner, repo }] = await Promise.all([getHeadCommitId({
@@ -158,6 +158,7 @@ const uploadAllFileChanges = async ({ branch, dir, messageHeadline, ignore, mess
158
158
  });
159
159
  if (!changedFiles.length) return;
160
160
  const fileChanges = await readFileChanges(dir, changedFiles);
161
+ console.dir(fileChanges, { depth: null });
161
162
  const commitId = await uploadFileChanges({
162
163
  dir,
163
164
  branch,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@skuba-lib/api",
3
- "version": "2.0.2",
3
+ "version": "2.0.3-build-package-patch-2-20260226003820",
4
4
  "description": "Node.js development API for skuba",
5
5
  "homepage": "https://github.com/seek-oss/skuba#readme",
6
6
  "bugs": {