mirror of
https://github.com/Eugeny/tabby.git
synced 2025-07-20 02:18:01 +00:00
support Solus Linux - fixes #4881
This commit is contained in:
@@ -18,7 +18,14 @@ export class POSIXShellsProvider extends ShellProvider {
|
||||
if (this.hostApp.platform === Platform.Windows) {
|
||||
return []
|
||||
}
|
||||
return (await fs.readFile('/etc/shells', { encoding: 'utf-8' }))
|
||||
let shellListPath = '/etc/shells'
|
||||
try {
|
||||
await fs.stat(shellListPath)
|
||||
} catch {
|
||||
// Solus Linux
|
||||
shellListPath = '/usr/share/defaults/etc/shells'
|
||||
}
|
||||
return (await fs.readFile(shellListPath, { encoding: 'utf-8' }))
|
||||
.split('\n')
|
||||
.map(x => x.trim())
|
||||
.filter(x => x && !x.startsWith('#'))
|
||||
|
Reference in New Issue
Block a user