Skip to content

Commit b027b12

Browse files
list platforms correctly
1 parent 1adae1a commit b027b12

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

bin/cocos

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
#!/bin/sh
1+
#!/bin/bash -l
22

33
COCOS_CONSOLE_BIN_DIRECTORY=$(dirname "$0")
44
COCOS_CONSOLE_BIN_DIRECTORY=$(cd "$COCOS_CONSOLE_BIN_DIRECTORY" && pwd -P)
55

6-
exec python "$COCOS_CONSOLE_BIN_DIRECTORY/cocos.py" "$@"
6+
python "$COCOS_CONSOLE_BIN_DIRECTORY/cocos.py" "$@"
77

bin/cocos.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -576,7 +576,7 @@ def parse_args(self, argv):
576576
if args.listplatforms and self._project is not None:
577577
platforms = cocos_project.Platforms(self._project, args.platform, args.proj_dir)
578578
p = platforms.get_available_platforms().keys()
579-
print('{' + json.dumps(p) + '}')
579+
print('{"platforms":' + json.dumps(p) + '}')
580580
sys.exit(0)
581581

582582
self.init(args)

0 commit comments

Comments
 (0)