@go-to-k/cdkd 0.5.1 → 0.6.0

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.
Binary file
package/dist/index.js CHANGED
@@ -3024,6 +3024,18 @@ var LockManager = class {
3024
3024
  );
3025
3025
  }
3026
3026
  }
3027
+ /**
3028
+ * Check whether a lock currently exists for a stack
3029
+ *
3030
+ * Returns true if a lock file is present in S3 (regardless of expiry).
3031
+ * This is intended for read-only inspection (e.g. `cdkd state list --long`),
3032
+ * not for acquisition decisions — use `acquireLock` for that, which has its
3033
+ * own expired-lock cleanup logic.
3034
+ */
3035
+ async isLocked(stackName) {
3036
+ const lockInfo = await this.getLockInfo(stackName);
3037
+ return lockInfo !== null;
3038
+ }
3027
3039
  /**
3028
3040
  * Release a lock for a stack
3029
3041
  */