Fastlane - use current git tag as version number - zsh

I'm trying to use the latest tag on a branch as the version number in an iOS project, using Fastlane.
If I run git describe --abbrev=0 --tags in my terminal I can see the latest tag output.
I'd like to pipe this value into increment_version_number in Fastlane.
To test this I have run -
fastlane action increment_version_number(version_number: $(git describe --abbrev=0 --tags))
in my terminal, but the output I get is
zsh: unknown file attribute: v
increment_version_number docs
Is it possible to do this?
Thanks

Running the command in the terminal has a different syntax - you need to supply the arguments inline.
fastlane run increment_version_number version_number:$(git describe --abbrev=0 --tags)"

Related

Having an Npx issue while executing npx firestore-algolia-search

I want to sync my old firestore data of a collection to algolia. I have followed the documentation provided and face issues with npx. If anyone could help me would mean a lot.
Here's the output I get if I use a PowerShell terminal
/bin/bash: C:/Program Files/nodejs/npx: No such file or directory
I receive this error when using bash in wsl even when providing the full path to npx and the script file.
Any help would mean a lot
I have tried and tested all the solutions I could find on the internet from using git bash to execute the script to using wsl to execute the bash script without any luck
Use npx firestore-algolia-search#0.5.14. Something is broken in 0.5.15.
EDIT: I created a github ticket for this issue.

Docfx failing on init command

I am trying to get docfx to generate a doc website based off of a C# library and I can't seem to get any of the commands covered in the documentation to work.
On the quickstart page it states to use the following command to initialize a template docfx init -q however when I run this command I get the following error message:
'init' was not matched. Did you mean 'new'?
'-q' was not matched. Did you mean '-h'?
Required command was not provided.
Unrecognized command or argument 'init'
Unrecognized command or argument '-q'
Usage:
docfx [options] [command]
Options:
--version Show version information
-?, -h, --help Show help and usage information
Commands:
new <templateName> Creates a new docset.
restore <directory> Restores dependencies before build.
build <directory> Builds a docset.
serve <directory> Serves content in a docset.
The documentation (as far as I can tell) doesn't cover the options displayed by the tools output. I have checked a number of times now to make sure I am not going insane but I definitely downloaded the package from the page listed on the quickstart page.
Does anyone regularly use Docfx and can tell me how to go about generating the html for my library?
Looks like you're using 3.x, which is undocumented.
You can download 2.59.2 here

Logging console output using Qt Installer Framework scripting

I added some console.log("xxxxxx") via component / controller scripting to my installer.
ie.
function Controller()
{
console.log("OS: " + systemInfo.productType);
}
How can I view the console log during the running of the installer?
Not sure if you can see a log during installation. But after a "successful" installation the TargetDir will contain a file named InstallationLog.txt that contains all the console.log lines from the installation process.
Edit: To see it live, do like #CherryDT points out in his comment: Run your installer from the command line and provide the -v parameter (fx my_installer.exe -v).
Edit: The previous Edit is slightly wrong, check #KcFnMi answer.
To see console.log information at runtime (the time you're running the installer, not the time you are building the installer) do:
installer.exe -d
or
installer --version
-d, --verbose Verbose mode. Prints out more information.
https://doc.qt.io/qtinstallerframework/ifw-cli.html
Note: It's not -v:
-v, --version Displays version information.

flyway sbt placeholder substitution not working

Using Flyway 2.3 on Windows, same result from command prompt and within cygwin. Production env is Linux, but haven't been able to test there yet.
My SQL file has the line:
alter table person add ${new_col} text;
I added the following to my build.sbt, based on what I saw on the the flyway sbt doc page:
flywayPlaceholders := Map(
"new_col" -> "temp_name"
)
When I run
> sbt flywayMigrate
I get this:
com.googlecode.flyway.core.api.FlywayException: No value provided for placeholder expressions: ${new_col}. Check your configuration!
Under cygwin it does work if I specify the substitution on the command line:
> sbt flywayMigrate -Dflyway.placeholders.new_col=temp_name
Command line plaveholder substitution doesn't work in Windows command prompt, but I suspect that's a different issue as none of my -D options are respected there.
I'm new to both sbt and Flyway, so I'm hoping this is something simple, but I couldn't find anything helpful by googling. thanks in advance for any help
The flywayPlaceholders in build.sbt are currently by the commandline configuration.
This is a bug in Flyway.
I created a pull request.

How to use XULRunner to run SQLite Manager outside of Firefox in Mac OS X Lion?

I have installed XULRunner 11.0 (xr) from here:
Downloads - sqlite-manager - Extension for Firefox and other apps to manage any sqlite database - Google Project Hosting
I have followed the steps listed here:
kiveo - Mac SQLite Manager Standalone App
I have read and tried the suggestions here (though they're for version 6.0):
stackoverflow: How to Install and run a XulRunner Application on Mac OS X?
I am able to get the help listing with this command:
/Library/Frameworks/XUL.framework/xulrunner-bin -h
I am able to run the app from Firefox using this command (after changing the max version in sqlitemanager-xr-0/application.ini to 11.0 from 11.0a1):
/Applications/Firefox.app/Contents/MacOS/firefox --app ~/Downloads/sqlitemanager-xr-0/application.ini
Here are the contents of the application.ini file:
[App]
Name=sqlite-manager
ID=SQLiteManager#mrinalkant.blogspot.com
Version=0.7.7
BuildID=201111132204
Vendor=lazierthanthou
Copyright=Copyright (c) 2008 - 2011 lazierthanthou
[Gecko]
MinVersion=2.0
MaxVersion=11.0
[XRE]
EnableExtensionManager=1
When I run the following command in Terminal, with or without sudo, it just immediately returns to the command prompt. There are no error messages. No application appears under Applications. Nothing seems to happen at all. (And, despite the stackoverflow page above noting that --install-app may not really be supported, it is in the XULRunner help listing - which I guess doesn't necessarily mean it'll work ;)
/Library/Frameworks/XUL.framework/xulrunner-bin --install-app Downloads/sqlitemanager-xr-0/ /Applications
Following a suggestion below, I checked for an exit code. The line above is returning 2.
Help?
Just like you did with Firefox, this command should run your app:
/Library/Frameworks/XUL.framework/xulrunner-bin --app ~/Downloads/sqlitemanager-xr-0/application.ini
Also, the --app switch is optional within XULRunner.
Here's how you can make a self-contained application you can run from the Dock.
Use the xulrunner --install-app command to create the application and then copy all contents of XUL.framework/Versions/Current into the generated application at /Applications/sqlite-manager.app/Contents/MacOS.
You can then create a wrapper script that runs the xulrunner within the generated app with the application.ini file as described here.
For example, put the following into sqlite-manager.app/Contents/MacOS/sqlite-manager and make it executable.
#!/usr/bin/env bash
APP_PATH="/Applications/sqlite-manager.app"
"$APP_PATH/Contents/MacOS/xulrunner" --app "$APP_PATH/Contents/Resources/application.ini"
Now you have to tell OS X to run sqlite-manager instead of xulrunner. You can do that by editing sqlite-manager.app/Contents/info.plist and setting CFBundleExecutable to sqlite-manager like this:
<key>CFBundleExecutable</key>
<string>sqlite-manager</string>
The only limitation of this approach is that it breaks when you move the application or rename it. I'd love suggestions on how to get rid of the absolute path within the sqlite-manager script.
try this:
firefox -chrome chrome://sqlitemanager/content/sqlitemanager.xul
or on OS X
/Applications/Firefox.app/Contents/MacOS/firefox -chrome chrome://sqlitemanager/content/sqlitemanager.xul
(found on http://www.egeek.me/2013/09/07/how-to-run-sqlite-manager-with-a-single-command/)
works fine for me on UBUNTU 12.04 to start sqlite manager without starting firefox first
If the install was successful, I think the app should be available in some usual place for your system (which wasn't mentioned, but I'm guessing OSX :). Have you looked under /Applications?
To see whether the command failed quietly, you could check its return value. Is there a verbose switch?
$ cd narnia
bash: cd: narnia: No such file or directory
$ echo $?
1
$ cd .
$ echo $?
0
$ cd narnia && echo "success"
bash: cd: narnia: No such file or directory
$ cd . && echo "success"
success

Resources