-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
removed our dendency of the main dcli library due to problems with wa…
…itfor no longer being supported indart. change the # bin/env from dcli to dart.
- Loading branch information
Showing
56 changed files
with
1,040 additions
and
377 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,108 +5,131 @@ | |
"type": "dart", | ||
"request": "launch", | ||
"program": "bin/onepub.dart", | ||
"args": ["doctor"] | ||
"args": [ | ||
"doctor" | ||
] | ||
}, | ||
{ | ||
"name": "onepub team create", | ||
"type": "dart", | ||
"request": "launch", | ||
"program": "bin/onepub.dart", | ||
"args": ["team", "create", "one"] | ||
} | ||
, | ||
"args": [ | ||
"team", | ||
"create", | ||
"one" | ||
] | ||
}, | ||
{ | ||
"name": "onepub login", | ||
"type": "dart", | ||
"request": "launch", | ||
"program": "bin/onepub.dart", | ||
"args": ["login"], | ||
"args": [ | ||
"login" | ||
], | ||
"console": "terminal" | ||
}, | ||
{ | ||
"name": "onepub logout", | ||
"type": "dart", | ||
"request": "launch", | ||
"program": "bin/onepub.dart", | ||
"args": ["logout"] | ||
} | ||
, | ||
"args": [ | ||
"logout" | ||
] | ||
}, | ||
{ | ||
"name": "onepub doctor", | ||
"type": "dart", | ||
"request": "launch", | ||
"program": "bin/onepub.dart", | ||
"args": ["doctor"] | ||
} | ||
, | ||
"args": [ | ||
"doctor" | ||
] | ||
}, | ||
{ | ||
"name": "onepub export", | ||
"type": "dart", | ||
"request": "launch", | ||
"program": "bin/onepub.dart", | ||
"args": ["export"] | ||
} | ||
, | ||
"args": [ | ||
"export" | ||
] | ||
}, | ||
{ | ||
"name": "onepub export to file", | ||
"type": "dart", | ||
"request": "launch", | ||
"program": "bin/onepub.dart", | ||
"args": ["export", "--file"] | ||
} | ||
|
||
, | ||
"args": [ | ||
"export", | ||
"--file" | ||
] | ||
}, | ||
{ | ||
"name": "onepub export CI/CD User", | ||
"type": "dart", | ||
"request": "launch", | ||
"program": "bin/onepub.dart", | ||
"args": ["export", "--user", "[email protected]"] | ||
} | ||
, | ||
"args": [ | ||
"export", | ||
"--user", | ||
"[email protected]" | ||
] | ||
}, | ||
{ | ||
"name": "onepub import", | ||
"type": "dart", | ||
"request": "launch", | ||
"program": "bin/onepub.dart", | ||
"args": ["import"], | ||
"env": {"ONEPUB_TOKEN" : "ABCDE"} | ||
"args": [ | ||
"import" | ||
], | ||
"env": { | ||
"ONEPUB_TOKEN": "ABCDE" | ||
} | ||
}, | ||
|
||
{ | ||
"name": "onepub pub private", | ||
"type": "dart", | ||
"request": "launch", | ||
"program": "bin/onepub.dart", | ||
"args": ["pub", "private"], | ||
"args": [ | ||
"pub", | ||
"private" | ||
], | ||
"console": "terminal" | ||
}, | ||
|
||
{ | ||
"name": "opub login", | ||
"type": "dart", | ||
"request": "launch", | ||
"program": "bin/opub.dart", | ||
"args": ["login"], | ||
"args": [ | ||
"login" | ||
], | ||
"console": "terminal" | ||
}, | ||
|
||
{ | ||
"name": "opub publish", | ||
"type": "dart", | ||
"request": "launch", | ||
"program": "/home/bsutton/git/onepub/onepub/bin/opub.dart", | ||
"args": ["publish"], | ||
"args": [ | ||
"publish" | ||
], | ||
"console": "terminal", | ||
"cwd": "/home/bsutton/git/dcli/dcli_core" | ||
}, | ||
|
||
{ | ||
"name": "opub get", | ||
"type": "dart", | ||
"request": "launch", | ||
"program": "bin/opub.dart", | ||
"args": ["get"], | ||
"args": [ | ||
"get" | ||
], | ||
"console": "terminal" | ||
}, | ||
{ | ||
|
@@ -115,28 +138,45 @@ | |
"request": "launch", | ||
"program": "/home/bsutton/git/onepub/onepub/bin/onepub.dart", | ||
"cwd": "/home/bsutton/git/setversion", | ||
"args": ["pub", "global","activate","setversion"], | ||
"args": [ | ||
"pub", | ||
"global", | ||
"activate", | ||
"setversion" | ||
], | ||
"console": "terminal" | ||
}, | ||
|
||
|
||
{ | ||
"name": "onepub pub private ", | ||
"type": "dart", | ||
"request": "launch", | ||
"program": "/home/bsutton/git/onepub/onepub/bin/onepub.dart", | ||
"args": ["pub", "private"], | ||
"args": [ | ||
"pub", | ||
"private" | ||
], | ||
"cwd": "/home/bsutton/git/dvault", | ||
"console": "terminal" | ||
}, | ||
|
||
{ | ||
"name": "test ct auth", | ||
"type": "dart", | ||
"request": "launch", | ||
"program": "/home/bsutton/git/onepub/onepub/tool/critical_test/pre_hook/auth.dart", | ||
"console": "terminal" | ||
}, | ||
|
||
{ | ||
"name": "onepub pub add ", | ||
"type": "dart", | ||
"request": "launch", | ||
"program": "/home/bsutton/git/onepub/onepub/bin/onepub.dart", | ||
"args": [ | ||
"pub", | ||
"add", | ||
"dcli" | ||
], | ||
"cwd": "/home/bsutton/git/issues/token", | ||
"console": "terminal" | ||
}, | ||
] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
#! /usr/bin/env dcli | ||
#! /usr/bin/env dart | ||
/* Copyright (C) OnePub IP Pty Ltd - All Rights Reserved | ||
* licensed under the GPL v2. | ||
* Written by Brett Sutton <[email protected]>, Jan 2022 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,8 @@ | |
* Written by Brett Sutton <[email protected]>, Jan 2022 | ||
*/ | ||
import 'package:args/command_runner.dart'; | ||
import 'package:dcli/dcli.dart'; | ||
import 'package:dcli_core/dcli_core.dart'; | ||
import 'package:dcli_terminal/dcli_terminal.dart'; | ||
import 'package:validators2/validators2.dart'; | ||
|
||
import '../api/api.dart'; | ||
|
@@ -47,7 +48,7 @@ Pass in a filename or leave blank to use the default filename.''') | |
final file = argResults!['file'] as bool; | ||
final user = argResults!['user'] as String?; | ||
|
||
if (!OnePubTokenStore().isLoggedIn(OnePubSettings.use().onepubApiUrl)) { | ||
if (!await OnePubTokenStore().isLoggedIn(OnePubSettings.use().onepubApiUrl)) { | ||
throw ExitException(exitCode: 1, message: ''' | ||
You must be logged in to run this command. | ||
run: onepub login | ||
|
@@ -72,7 +73,7 @@ run: onepub login | |
throw ExitException(exitCode: 1, message: response.errorMessage!); | ||
} | ||
} else { | ||
onepubToken = OnePubTokenStore().load(); | ||
onepubToken = await OnePubTokenStore().load(); | ||
} | ||
print(orange('Exporting OnePub token for ' | ||
'${OnePubSettings.use().organisationName}.')); | ||
|
Oops, something went wrong.