Saturday, 25 September 2021

Codepush & Ionic Integration

 1. npm install cordova-plugin-code-push

2. npm install @ionic-native/code-push

3. npm install -g appcenter-cli    

4. appcenter login

5. ionic cordova build android

//6. appcenter codepush release-cordova -a Digital-Venus/APLUSSBOSS-Android-UAT -m

7. appcenter codepush release-cordova -a Digital-Venus/APLUSBOSS-APP-V2 -m


# Release a mandatory update with a changelog

appcenter codepush release -a <ownerName>/MyApp-ios -c ios/App/App/public/ -m --description "Modified the header color"


# Release a dev Android build to just 1/4 of your end users

appcenter codepush release -a <ownerName>/MyApp-android -c android/app/src/main/assets/public/ --rollout 25


# Release an update that targets users running any 1.1.* binary, as opposed to

# limiting the update to exact version name in the config.xml file

appcenter codepush release -a <ownerName>/MyApp-android -c android/app/src/main/assets/public/ --target-binary-version "~1.1.0"


# Release an update now but mark it as disabled

# so that no users can download it yet

appcenter codepush release -a <ownerName>/MyApp-ios -c ios/App/App/public/ -x


# Release an update signed by private key (public key should be configured for application)

appcenter codepush release -a <ownerName>/MyApp-android -c android/app/src/main/assets/public/ --privateKeyPath ~/rsa/private_key.pem


references

https://github.com/mapiacompany/capacitor-codepush


config.xml

<preference name="APP_SECRET" value="7056bb94-2703-4e01-ab79-66848505b6a9" />

<preference name="APPCENTER_ANALYTICS_ENABLE_IN_JS" value="true" />

<preference name="CodePushDeploymentKey" value="OrnEAKcjIXFcKo4He7YoHaBN9BEIcg35AdbTM" />

Ionic Cordova platform - android 9.1 sdk build tools ^31.0.0 issue

C:\Users\$user\AppData\Local\Android\Sdk\build-tools\31.0.0
 

This is happened because dx files are missing from Android SDK Build Tools 31.0.0 and replaced with d8 files. Try to modify Android SDK Build Tools 31.0.0 by:
  1. In the Android SDK Build Tools 31.0.0 folder, create a copy of d8.bat and rename it to dx.bat.
  1. In the lib folder, create a copy of d8.jar and rename it to dx.jar.



Additional Check ionic cordova version

Method 1


Method 2 :
cordova -v

to see the currently running version. Run the npm info command

npm info cordova

for a longer listing that includes the current version along with other available version numbers

Thursday, 23 September 2021

NPM Specific Version Package

 

How To Know Package Versions Available




If you want to know the exact version of a package to install, you can simply search for it on the npm public registry database

Or, you can simply run the following command to check the available versions on the npm registry:

  npm view [package-name] versions

 

If you want to know the specific latest version of a package available on the npm registry, run the following command:

  npm view [package-name] version

 

For example, here is how you can check the latest version of the Renovate package:

resource :

https://www.whitesourcesoftware.com/free-developer-tools/blog/npm-install-specific-version/

Sunday, 19 September 2021

Issue with gradle

 


Apparently you should accept the license,so in your command promp:

cd /d "%ANDROID_SDK_ROOT%/tools/bin"

and then

sdkmanager --licenses

just accept the license and the error should goes away.

request headers in http options (angular)

 https://stackoverflow.com/questions/53980413/angular-common-http-has-no-exported-member-requestoptions