I distributed a Flutter app using fastlane and Firebase App Distribution. I needed to distribute it again so I incremented the build number in pubspec.yaml file: version: 1.0.0+1 => 1.0.0+2 and Xcode's Build: 1 => 2 and ran git commit and ran fastlane command but the new version of release file wasn't uploaded on App Distribution.
What am I missing?
[18:38:59]: ------------------------------
[18:38:59]: --- Step: default_platform ---
[18:38:59]: ------------------------------
[18:38:59]: Driving the lane 'android development' 🚀
[18:38:59]: ---------------------------------------
[18:38:59]: --- Step: firebase_app_distribution ---
[18:38:59]: ---------------------------------------
[18:38:59]: Authenticating with FIREBASE_TOKEN environment variable
[18:38:59]: 🔐 Authenticated successfully.
[18:39:01]: ✅ This APK has been uploaded before. Skipping upload step.
[18:39:02]: ✅ Posted release notes.
[18:39:03]: ✅ Added testers/groups.
[18:39:03]: 🎉 App Distribution upload finished successfully.
+------+---------------------------+-------------+
| fastlane summary |
+------+---------------------------+-------------+
| Step | Action | Time (in s) |
+------+---------------------------+-------------+
| 1 | default_platform | 0 |
| 2 | firebase_app_distribution | 3 |
+------+---------------------------+-------------+
[18:39:03]: fastlane.tools finished successfully 🎉
Then build the Android apk in release as shown below:
flutter build apk --release
Now for deployment, you have to run the fastlane workflow:
cd android && fastlane deploy && cd -
android/fastlane/Fastfile
For more details
Related
I have a simple React application with an Amplify configuration. When I try to publish it using Amplify (Mac) it ends with the following error:
❯ amplify publish
✔ Successfully pulled backend environment dev from the cloud.
Current Environment: dev
| Category | Resource name | Operation | Provider plugin |
| -------- | ---------------------------- | --------- | ----------------- |
| Api | sls-demo-twitter-state-api-2 | No Change | |
| Hosting | amplifyhosting | No Change | awscloudformation |
No changes detected
Publish started for amplifyhosting
command execution terminated with error
An error occurred during the publish operation: spawn npm.cmd ENOENT
The same configuration runs without any problems on my other client (Windows). Actually Amplify tries to build the app first and this step does not work. I cannot find reason for this.
"amplify publish" basically runs the build & start commands from amplify project configuration,
that you can reconfigure using amplify configure project.
I hope in your machine(Mac) npm is missing.
Install node brew install node and run amplify publish
I am working with flyway Db migration, and I have download flyway zip folder and placed into my local computer.
I have two files in the sql folder, i.e V1__Create_person_table.sql and V2__Add_people.sql.
Flyway info
Flyway Community Edition 5.2.4 by Boxfuse
Database: jdbc:h2:file:./foobardb (H2 1.4)
Schema version: << Empty Schema >>
+-----------+---------+---------------------+------+--------------+---------+
| Category | Version | Description | Type | Installed On | State |
+-----------+---------+---------------------+------+--------------+---------+
| Versioned | 1 | Create person table | SQL | | Pending |
| Versioned | 2 | Add people | SQL | | Pending |
+-----------+---------+---------------------+------+--------------+---------+
Flyway migrate
Flyway Community Edition 5.2.4 by Boxfuse
Database: jdbc:h2:file:./foobardb (H2 1.4)
Successfully validated 2 migrations (execution time 00:00.020s)
Creating Schema History table: "PUBLIC"."flyway_schema_history"
Current version of schema "PUBLIC": << Empty Schema >>
Migrating schema "PUBLIC" to version 1 - Create person table
Migrating schema "PUBLIC" to version 2 - Add people
Successfully applied 2 migrations to schema "PUBLIC" (execution time 00:00.092s)
Flyway info
Flyway Community Edition 5.2.4 by Boxfuse
Database: jdbc:h2:file:./foobardb (H2 1.4)
Schema version: 2
+-----------+---------+---------------------+------+---------------------+---------+
| Category | Version | Description | Type | Installed On | State |
+-----------+---------+---------------------+------+---------------------+---------+
| Versioned | 1 | Create person table | SQL | 2019-08-19 12:12:40 | Success |
| Versioned | 2 | Add people | SQL | 2019-08-19 12:12:40 | Success |
+-----------+---------+---------------------+------+---------------------+---------+
Now, here the question is: if I want to update or edit somehing in above two sql files, how can I do that, should I edit existing file version 1, version 2 and
save the file and run all the above command again?
You should not edit your existed scripts. I have to add a new one e.g. V3__Update_person_table.sql and correctly update it.
P.S.
In the big project, we have tens of scripts that iteratively modify the empty database to achieve a current status.
After that, usually, when moving to the next release version, we merge all existed scripts into one or two (when we do not need to keep history anymore).
Notes
This is correct. We do not change existed scripts (this is part of CI/CD). All changes should be added additionally with new scripts. Flyway accepts a directory with all scripts.
I have installed Osquery utility on my machine. When I fire an SQL command, it gives output to STDOUT. Is there any way to redirect that output to a file?
$ sudo osqueryi
I0314 10:57:51.644351 3958 database.cpp:563] Checking database version for migration
I0314 10:57:51.644912 3958 database.cpp:587] Performing migration: 0 -> 1
I0314 10:57:51.645279 3958 database.cpp:619] Migration 0 -> 1 successfully completed!
I0314 10:57:51.645627 3958 database.cpp:587] Performing migration: 1 -> 2
I0314 10:57:51.646088 3958 database.cpp:619] Migration 1 -> 2 successfully completed!
Using a virtual database. Need help, type '.help'
osquery>
osquery>
osquery> SELECT * from memory_info;
+--------------+-------------+----------+----------+-------------+-----------+----------+------------+-----------+
| memory_total | memory_free | buffers | cached | swap_cached | active | inactive | swap_total | swap_free |
+--------------+-------------+----------+----------+-------------+-----------+----------+------------+-----------+
| 513617920 | 270921728 | 15110144 | 99860480 | 0 | 145080320 | 59494400 | 0 | 0 |
+--------------+-------------+----------+----------+-------------+-----------+----------+------------+-----------+
osquery>
I want this output in a file. I checked Osquery official documentation. But it hasn't been helpful to solve this particular problem. https://osquery.readthedocs.io/en/stable/introduction/sql/#sql-as-understood-by-osquery
You can use the redirection facilities of your shell:
$ osqueryi --json 'select * from osquery_info' > res.json
$ cat res.json
[
{"build_distro":"10.12","build_platform":"darwin","config_hash":"e7c68185a7252c23585d53d04ecefb77b3ebf99c","config_valid":"1","extensions":"inactive","instance_id":"38201952-9a75-41dc-b2f8-188c2119cda1","pid":"26255","start_time":"1552676034","uuid":"4740D59F-699E-5B29-960B-979AAF9BBEEB","version":"3.3.0","watcher":"-1"}
]
Note that in this example we use JSON output. There are other options available: --csv, --line, --list.
As seph explained in https://stackoverflow.com/a/55164199/491710, it is a common use-case to schedule queries in osqueryd and push the results into a logging pipeline.
osqueryi is generally for interactive use. When saving to files, or having osquery part of a data pipeline, people usually configure scheduled queries with osqueryd.
https://osquery.readthedocs.io/en/stable/deployment/configuration/ has some pretty simple examples of a configuration.
You could also specify the query on the command line, and then do whatever you're doing in the shell.
WE have flyway integrated with Redshift and we are using this as a simple java main program to run all our schema migrations. We also use the info command to print the current version of the database, However this command successfully runs or at least appears to run but does not print the version number.
We have version 4.2 of the flyway jar. What is that we may be missing? Thanks
To manually recreate what the info command line option does in java code you can copy what its implementation does (from the source):
MigrationInfoDumper.dumpToAsciiTable(flyway.info().all())
An example from the docs is shown below:
+-------------+------------------------+---------------------+---------+
| Version | Description | Installed on | State |
+-------------+------------------------+---------------------+---------+
| 1 | Initial structure | | Pending |
| 1.1 | Populate table | | Pending |
| 1.3 | And his brother | | Pending |
+-------------+------------------------+---------------------+---------+
I can check a bundle state from Karaf Console by doing:-
karaf#root>bundle:list | grep camel-test
246 | Active | 50 | 2.16.1 | camel-test
Is there a way I can do this programatically via some script running on the same machine as Karaf or via some REST End Point that Karaf exposes?
I am using Karaf 3.0.5 running under ServiceMix 6.0.1.
As discussed in Karaf User Forum I am able to achieve it using the karaf client:-
jabong#jabong1143:~/Downloads/apache-servicemix-6.1.0/bin$ ./client -l 0 -u karaf "bundle:list" | grep camel-test
246 | Active | 50 | 2.16.1 | camel-test