MCPcopy Create free account
hub / github.com/decaporg/decap-cms / deleteRepositories

Function deleteRepositories

cypress/plugins/gitlab.js:98–112  ·  view source on GitHub ↗
({ owner, repo, tempDir })

Source from the content-addressed store, hash-verified

96}
97
98async function deleteRepositories({ owner, repo, tempDir }) {
99 const { token } = getEnvs();
100
101 const errorHandler = e => {
102 if (e.status !== 404) {
103 throw e;
104 }
105 };
106
107 console.log('Deleting repository', `${owner}/${repo}`);
108 await fs.remove(tempDir);
109
110 const client = getGitLabClient(token);
111 await client.Projects.remove(`${owner}/${repo}`).catch(errorHandler);
112}
113
114async function resetOriginRepo({ owner, repo, tempDir }) {
115 console.log('Resetting origin repo:', `${owner}/${repo}`);

Callers 1

teardownGitLabFunction · 0.70

Calls 2

getGitLabClientFunction · 0.85
getEnvsFunction · 0.70

Tested by

no test coverage detected