Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit bd6859c

Browse filesBrowse files
committed
Use core.group() instead of startGroup/endGroup
1 parent 223e443 commit bd6859c
Copy full SHA for bd6859c

2 files changed

+28-30Lines changed: 28 additions & 30 deletions

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎common.js‎

Copy file name to clipboardExpand all lines: common.js
+14-15Lines changed: 14 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -360,24 +360,23 @@ export function setupPath(newPathEntries) {
360360
const originalPath = process.env[envPath].split(path.delimiter)
361361
let cleanPath = originalPath.filter(entry => !/\bruby\b/i.test(entry))
362362

363-
core.startGroup(`Modifying ${envPath}`)
364-
365-
// First remove the conflicting path entries
366-
if (cleanPath.length !== originalPath.length) {
367-
console.log(`Entries removed from ${envPath} to avoid conflicts with default Ruby:`)
368-
for (const entry of originalPath) {
369-
if (!cleanPath.includes(entry)) {
370-
console.log(` ${entry}`)
363+
core.group(`Modifying ${envPath}`, async () => {
364+
// First remove the conflicting path entries
365+
if (cleanPath.length !== originalPath.length) {
366+
console.log(`Entries removed from ${envPath} to avoid conflicts with default Ruby:`)
367+
for (const entry of originalPath) {
368+
if (!cleanPath.includes(entry)) {
369+
console.log(` ${entry}`)
370+
}
371371
}
372+
core.exportVariable(envPath, cleanPath.join(path.delimiter))
372373
}
373-
core.exportVariable(envPath, cleanPath.join(path.delimiter))
374-
}
375374

376-
console.log(`Entries added to ${envPath} to use selected Ruby:`)
377-
for (const entry of newPathEntries) {
378-
console.log(` ${entry}`)
379-
}
380-
core.endGroup()
375+
console.log(`Entries added to ${envPath} to use selected Ruby:`)
376+
for (const entry of newPathEntries) {
377+
console.log(` ${entry}`)
378+
}
379+
})
381380

382381
core.addPath(newPathEntries.join(path.delimiter))
383382
}
Collapse file

‎dist/index.js‎

Copy file name to clipboardExpand all lines: dist/index.js
+14-15Lines changed: 14 additions & 15 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.