File tree Expand file tree Collapse file tree 3 files changed +4
-6
lines changed Expand file tree Collapse file tree 3 files changed +4
-6
lines changed Original file line number Diff line number Diff line change 5
5
"shell-version" : [
6
6
" 45"
7
7
],
8
- "version" : 6 ,
8
+ "version" : 7 ,
9
9
"url" : " https://github.com/rahulhaque/php-laravel-valet-gnome-shell-extension" ,
10
10
"settings-schema" : " org.gnome.shell.extensions.php-laravel-valet"
11
11
}
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1
1
import GLib from 'gi://GLib' ;
2
- import Bytes from 'gi://GLib/Bytes' ;
3
2
4
3
export function safeSpawn ( cmd ) {
5
4
try {
@@ -16,19 +15,19 @@ export function shellSpawn(cmd) {
16
15
17
16
export function phpVersion ( ) {
18
17
const res = safeSpawn ( '/bin/bash -c "php -v | grep -Po \'PHP\\s+\\d+.\\d+(?:(.\\d+))?\'"' ) ;
19
- if ( res [ 3 ] == 0 ) return Bytes . toString ( res [ 1 ] ) . replace ( / \n $ / , '' ) ;
18
+ if ( res [ 3 ] == 0 ) return String . fromCharCode ( ... res [ 1 ] ) . replace ( / \n $ / , '' ) ;
20
19
return false ;
21
20
}
22
21
23
22
export function phpList ( ) {
24
23
const res = safeSpawn ( 'ls /etc/php' ) ;
25
- if ( res [ 3 ] == 0 ) return Bytes . toString ( res [ 1 ] ) . split ( '\n' ) . filter ( item => ! ! item ) . reverse ( ) ;
24
+ if ( res [ 3 ] == 0 ) return String . fromCharCode ( ... res [ 1 ] ) . split ( '\n' ) . filter ( item => ! ! item ) . reverse ( ) ;
26
25
return false ;
27
26
}
28
27
29
28
export function valetStatus ( ) {
30
29
const res = safeSpawn ( '/bin/bash -c "valet --version && valet status"' ) ;
31
- if ( res [ 3 ] == 0 ) return Bytes . toString ( res [ 1 ] ) . split ( '\n' ) . filter ( item => ! ! item ) ;
30
+ if ( res [ 3 ] == 0 ) return String . fromCharCode ( ... res [ 1 ] ) . split ( '\n' ) . filter ( item => ! ! item ) ;
32
31
return false ;
33
32
}
34
33
You can’t perform that action at this time.
0 commit comments