mirror of
https://github.com/expo/turtle.git
synced 2026-11-14 19:12:55 -10:00
Compare commits
12
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8e10aacf59 | ||
|
|
3dd74ef406 | ||
|
|
87f7085fc4 | ||
|
|
0b0b5a7c72 | ||
|
|
d6dee79bcf | ||
|
|
db05eeeed3 | ||
|
|
cc317a6572 | ||
|
|
149073466d | ||
|
|
776aec445b | ||
|
|
d6432b6455 | ||
|
|
81f3a0e300 | ||
|
|
167766519e |
No files matched your search
+12
-2
@@ -5,6 +5,16 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
||||
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
||||
|
||||
## [Unreleased]
|
||||
### Added
|
||||
- Sending build duration in AWS SQS messages (of `FINISHED` and `ERRORED` types).
|
||||
|
||||
## [0.5.4] - 2019-01-22
|
||||
### Changed
|
||||
- Update iOS shell app for SDK32 to [`expo/expo#0847c10`](https://github.com/expo/expo/commit/0847c1073d38c366866f3d9279ddd662da47dc9b), i.e. v2.10.3 with fixed WebView navigation scheme and upgraded Facebook SDK.
|
||||
|
||||
## [0.5.3] - 2019-01-21
|
||||
### Fixed
|
||||
- Building Android standalone apps ([not accepted license issue](https://github.com/expo/expo/issues/3266)) - updated Android build tools (`build-tools;28.0.3`, `platforms;android-28`).
|
||||
|
||||
## [0.5.2] - 2019-01-18
|
||||
### Added
|
||||
@@ -18,11 +28,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
|
||||
## [0.5.1] - 2019-01-16
|
||||
### Changed
|
||||
- Update Android shell app for SDK32 that includes react-native-screens@1.0.0-alpha.22
|
||||
- Update Android shell app for SDK32 that includes `[email protected]`.
|
||||
|
||||
## [0.5.0] - 2019-01-16
|
||||
### Added
|
||||
- Turtle version is added to onFinish and onError build messages.
|
||||
- Turtle version is added to the `onFinish` and `onError` build messages.
|
||||
### Changed
|
||||
- A version property value being sent to the queue. It's now the version number
|
||||
from `package.json` instead of `new`/`old` indicator.
|
||||
|
||||
@@ -29,3 +29,5 @@ To submit a pull request:
|
||||
## Publishing a release
|
||||
- To release a new version of `turtle-cli`, run `yarn release` command.
|
||||
- If you wish to release a new *beta* version of `turtle-cli`, run `yarn release:beta` instead.
|
||||
- Update [Changelog](CHANGELOG.md).
|
||||
- In a terminal, `cd` into [expo/turtle-cli-example](https://github.com/expo/turtle-cli-example) repository, run `yarn update-turtle-cli-version` (this script updates `turtle-cli` version number in CI configuration files and commits the changes) and then run `git push`. Thanks!
|
||||
+3
-3
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "turtle-cli",
|
||||
"version": "0.5.2",
|
||||
"version": "0.5.5",
|
||||
"description": "The command-line tool for building standalone Expo apps",
|
||||
"preferGlobal": true,
|
||||
"scripts": {
|
||||
@@ -28,8 +28,8 @@
|
||||
"test:smoke": "yarn test --config jest/smoke-config.json --forceExit",
|
||||
"test:smoke:android": "yarn test:smoke --testNamePattern=android",
|
||||
"test:smoke:ios": "PLATFORM=ios yarn test:smoke --testNamePattern=iOS",
|
||||
"release": "release-it",
|
||||
"release:beta": "yarn release -c .release-it.beta.json --preRelease=beta",
|
||||
"release": "./scripts/release.sh",
|
||||
"release:beta": "./scripts/releaseBeta.sh",
|
||||
"ssh:android:pods-names": "./scripts/ssh/findAndroidPods.sh",
|
||||
"ssh:android:connect": "./scripts/ssh/connectToAndroidPod.sh",
|
||||
"ssh:ios:ips": "./scripts/ssh/findIosIps.sh",
|
||||
|
||||
Executable
+11
@@ -0,0 +1,11 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
set -eo pipefail
|
||||
|
||||
ROOT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )"/.. && pwd )"
|
||||
|
||||
$ROOT_DIR/node_modules/.bin/release-it
|
||||
echo
|
||||
echo "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
|
||||
echo "!!!! PLEASE REMEMBER TO UPDATE CHANGELOG !!!!"
|
||||
echo "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
|
||||
Executable
+7
@@ -0,0 +1,7 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
set -eo pipefail
|
||||
|
||||
ROOT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )"/.. && pwd )"
|
||||
|
||||
$ROOT_DIR/node_modules/.bin/release-it -c $ROOT_DIR/.release-it.beta.json --preRelease=beta
|
||||
@@ -1 +1 @@
|
||||
s3://exp-artifacts/ios-shell-builder-sdk-latest-e3855783ed0618f4dcf326dc353c6e2951e05c49.tar.gz
|
||||
s3://exp-artifacts/ios-shell-builder-sdk-latest-f3de2d71b10c058501e99e0b1ce9b5a991e291be.tar.gz
|
||||
+16
-7
@@ -75,20 +75,21 @@ async function processJob(jobData: any) {
|
||||
logger.info('The job has been cancelled');
|
||||
} else {
|
||||
redis.registerListener(job.id, () => deleteMessage(priority, receiptHandle));
|
||||
const startTimestamp = +new Date();
|
||||
const startTimestamp = Date.now();
|
||||
let buildFailed = false;
|
||||
const buildType = _.get(job, 'config.buildType', 'default');
|
||||
try {
|
||||
const success = await build(job);
|
||||
buildStatusMetric.add(buildType, success);
|
||||
buildFailed = !success;
|
||||
const status = await build(job);
|
||||
buildStatusMetric.add(buildType, status);
|
||||
buildFailed = !status;
|
||||
} catch (err) {
|
||||
buildStatusMetric.add(buildType, false);
|
||||
buildFailed = true;
|
||||
throw err;
|
||||
} finally {
|
||||
const endTimestamp = +new Date();
|
||||
const endTimestamp = Date.now();
|
||||
const turtleBuildDurationSecs = Math.ceil((endTimestamp - startTimestamp) / 1000);
|
||||
logger.info(`BuildID=${job.id} Build duration=${turtleBuildDurationSecs}`);
|
||||
buildDurationMetric.addTurtleDuration(buildType, turtleBuildDurationSecs, !buildFailed);
|
||||
if (job.messageCreatedTimestamp) {
|
||||
const totalBuildDurationSecs = Math.ceil(
|
||||
@@ -123,7 +124,9 @@ function failAfterMaxJobTime(priority: string, receiptHandle: string, job: any)
|
||||
}
|
||||
|
||||
async function build(job: any) {
|
||||
const startTimestamp = Date.now();
|
||||
const s3Url = await logger.init(job);
|
||||
const calculateBuildDuration = () => Math.ceil((Date.now() - startTimestamp) / 1000);
|
||||
|
||||
try {
|
||||
await sqs.sendMessage(job.id, BUILD.JOB_STATES.IN_PROGRESS, {
|
||||
@@ -131,11 +134,17 @@ async function build(job: any) {
|
||||
logFormat: 'json',
|
||||
});
|
||||
const result = await (builders as any)[job.platform](job);
|
||||
sqs.sendMessage(job.id, BUILD.JOB_STATES.FINISHED, { ...result, turtleVersion });
|
||||
const buildDuration = calculateBuildDuration();
|
||||
sqs.sendMessage(job.id, BUILD.JOB_STATES.FINISHED, {
|
||||
...result,
|
||||
turtleVersion,
|
||||
buildDuration,
|
||||
});
|
||||
return true;
|
||||
} catch (err) {
|
||||
logErrorOnce(err);
|
||||
sqs.sendMessage(job.id, BUILD.JOB_STATES.ERRORED, { turtleVersion });
|
||||
const buildDuration = calculateBuildDuration();
|
||||
sqs.sendMessage(job.id, BUILD.JOB_STATES.ERRORED, { turtleVersion, buildDuration });
|
||||
return false;
|
||||
} finally {
|
||||
await logger.cleanup(job);
|
||||
|
||||
Reference in new issue
Block a user