From b23879ba32cc0bb5829ee9c3f1c0550420a7ef41 Mon Sep 17 00:00:00 2001 From: Moritz Date: Thu, 22 Aug 2024 11:03:52 +0200 Subject: [PATCH] Trying to publish `intl4x` yet again (#879) * Move stuff * Fix path in readme * Merge branch 'main' into fixYetAgain * Add changelog --- pkgs/intl4x/CHANGELOG.md | 1 + pkgs/intl4x/hook/README.md | 2 +- pkgs/intl4x/hook/build.dart | 5 ++--- pkgs/intl4x/{hook => lib/src/hook_helpers}/hashes.dart | 0 pkgs/intl4x/{hook => lib/src/hook_helpers}/version.dart | 0 pkgs/intl4x/tool/regenerate_hashes.dart | 5 ++--- 6 files changed, 6 insertions(+), 7 deletions(-) rename pkgs/intl4x/{hook => lib/src/hook_helpers}/hashes.dart (100%) rename pkgs/intl4x/{hook => lib/src/hook_helpers}/version.dart (100%) diff --git a/pkgs/intl4x/CHANGELOG.md b/pkgs/intl4x/CHANGELOG.md index 28660058..bb20534f 100644 --- a/pkgs/intl4x/CHANGELOG.md +++ b/pkgs/intl4x/CHANGELOG.md @@ -1,6 +1,7 @@ ## 0.10.0 - Upgrade minimum SDK to `3.6.0-0`. +- Move hook code to `lib/src/`. ## 0.9.2 diff --git a/pkgs/intl4x/hook/README.md b/pkgs/intl4x/hook/README.md index 7663ee30..a0fdcb44 100644 --- a/pkgs/intl4x/hook/README.md +++ b/pkgs/intl4x/hook/README.md @@ -9,6 +9,6 @@ #### Second PR 1. Create PR. 2. Run `bash tools/regenerate_bindings.sh`, and fix resulting errors. -3. Update `const version` in `hook/version.dart` to tag. +3. Update `const version` in `version.dart` to tag. 4. Regenerate hashes using `cd pkgs/intl4x/; dart --enable-experiment=native-assets run tool/regenerate_hashes.dart`. 5. Land PR. diff --git a/pkgs/intl4x/hook/build.dart b/pkgs/intl4x/hook/build.dart index 010bbd99..9c9832d4 100644 --- a/pkgs/intl4x/hook/build.dart +++ b/pkgs/intl4x/hook/build.dart @@ -5,12 +5,11 @@ import 'dart:io'; import 'package:crypto/crypto.dart' show sha256; +import 'package:intl4x/src/hook_helpers/hashes.dart'; +import 'package:intl4x/src/hook_helpers/version.dart'; import 'package:native_assets_cli/native_assets_cli.dart'; import 'package:path/path.dart' as path; -import 'hashes.dart'; -import 'version.dart'; - const crateName = 'icu_capi'; const package = 'intl4x'; const assetId = 'src/bindings/lib.g.dart'; diff --git a/pkgs/intl4x/hook/hashes.dart b/pkgs/intl4x/lib/src/hook_helpers/hashes.dart similarity index 100% rename from pkgs/intl4x/hook/hashes.dart rename to pkgs/intl4x/lib/src/hook_helpers/hashes.dart diff --git a/pkgs/intl4x/hook/version.dart b/pkgs/intl4x/lib/src/hook_helpers/version.dart similarity index 100% rename from pkgs/intl4x/hook/version.dart rename to pkgs/intl4x/lib/src/hook_helpers/version.dart diff --git a/pkgs/intl4x/tool/regenerate_hashes.dart b/pkgs/intl4x/tool/regenerate_hashes.dart index 1849b1cc..d1abc062 100644 --- a/pkgs/intl4x/tool/regenerate_hashes.dart +++ b/pkgs/intl4x/tool/regenerate_hashes.dart @@ -1,10 +1,9 @@ import 'dart:io'; import 'package:crypto/crypto.dart'; +import 'package:intl4x/src/hook_helpers/version.dart'; import 'package:native_assets_cli/native_assets_cli.dart'; -import '../hook/version.dart'; - final httpClient = HttpClient(); Future main(List args) async { @@ -29,7 +28,7 @@ Future main(List args) async { } httpClient.close(force: true); - await File('hook/hashes.dart').writeAsString(''' + await File('lib/src/hook_helpers/hashes.dart').writeAsString(''' // Copyright (c) 2024, the Dart project authors. Please see the AUTHORS file // for details. All rights reserved. Use of this source code is governed by a // BSD-style license that can be found in the LICENSE file.