- retrieve owner and repo by repository again

This commit is contained in:
Mike Penz
2020-10-18 12:17:31 +02:00
parent 3dfff6952e
commit af4fa53849
3 changed files with 7 additions and 7 deletions
Generated Vendored
+4 -4
View File
@@ -301,7 +301,7 @@ const gitHelper_1 = __webpack_require__(353);
const github = __importStar(__webpack_require__(5438)); const github = __importStar(__webpack_require__(5438));
const configuration_1 = __webpack_require__(5527); const configuration_1 = __webpack_require__(5527);
function run() { function run() {
var _a, _b, _c, _d; var _a, _b, _c, _d, _e, _f;
return __awaiter(this, void 0, void 0, function* () { return __awaiter(this, void 0, void 0, function* () {
core.setOutput('failed', false); // mark the action not failed by default core.setOutput('failed', false); // mark the action not failed by default
core.startGroup(`📘 Reading input values`); core.startGroup(`📘 Reading input values`);
@@ -314,8 +314,8 @@ function run() {
const configuration = utils_1.resolveConfiguration(repositoryPath, configurationFile); const configuration = utils_1.resolveConfiguration(repositoryPath, configurationFile);
// read in repository inputs // read in repository inputs
const token = core.getInput('token'); const token = core.getInput('token');
const owner = (_a = core.getInput('owner')) !== null && _a !== void 0 ? _a : github.context.repo.owner; const owner = (_b = (_a = core.getInput('owner')) !== null && _a !== void 0 ? _a : github.context.repo.owner) !== null && _b !== void 0 ? _b : core.getInput('repository').split('/')[0];
const repo = (_b = core.getInput('repo')) !== null && _b !== void 0 ? _b : github.context.repo.repo; const repo = (_d = (_c = core.getInput('repo')) !== null && _c !== void 0 ? _c : github.context.repo.repo) !== null && _d !== void 0 ? _d : core.getInput('repository').split('/')[1];
// read in from, to tag inputs // read in from, to tag inputs
const fromTag = core.getInput('fromTag'); const fromTag = core.getInput('fromTag');
let toTag = core.getInput('toTag'); let toTag = core.getInput('toTag');
@@ -371,7 +371,7 @@ function run() {
failOnError, failOnError,
configuration configuration
}); });
core.setOutput('changelog', (_d = (_c = (yield releaseNotes.pull(token))) !== null && _c !== void 0 ? _c : configuration.empty_template) !== null && _d !== void 0 ? _d : configuration_1.DefaultConfiguration.empty_template); core.setOutput('changelog', (_f = (_e = (yield releaseNotes.pull(token))) !== null && _e !== void 0 ? _e : configuration.empty_template) !== null && _f !== void 0 ? _f : configuration_1.DefaultConfiguration.empty_template);
} }
catch (error) { catch (error) {
core.setFailed(error.message); core.setFailed(error.message);
Generated Vendored
+1 -1
View File
File diff suppressed because one or more lines are too long
+2 -2
View File
@@ -27,8 +27,8 @@ async function run(): Promise<void> {
// read in repository inputs // read in repository inputs
const token = core.getInput('token') const token = core.getInput('token')
const owner = core.getInput('owner') ?? github.context.repo.owner const owner = core.getInput('owner') ?? github.context.repo.owner ?? core.getInput('repository').split('/')[0]
const repo = core.getInput('repo') ?? github.context.repo.repo const repo = core.getInput('repo') ?? github.context.repo.repo ?? core.getInput('repository').split('/')[1]
// read in from, to tag inputs // read in from, to tag inputs
const fromTag = core.getInput('fromTag') const fromTag = core.getInput('fromTag')
let toTag = core.getInput('toTag') let toTag = core.getInput('toTag')