I want to use kartik yii-grid to make editable grid. But when i am trying to install it though composer using following command
php composer.phar require kartik-v/yii2-grid "#dev"
But it will update so many thing from my vendor also even yii2 framework bootstrap. Can any one suggest me to install this widget without effecting my other vendor stuff?
Add:
"kartik-v/yii2-grid": "#dev"
to the require section of your composer.json file.
Then run:
php composer.phar update kartik-v/yii2-grid
Installing or updating a single dependency is outlined in composers documentation here.
https://getcomposer.org/doc/01-basic-usage.md#package-versions
Composer installs what is specified in composer.json file. If you want all of the dependencies are never updated - in composer.json specify the exact version of the package, then the composer would never try to update it.
So that you are trying to bypass the upgrade of packages during the installation - this is a bad decision, you should have the right composer.json, rather than trying to deceive composer
=====
Also from https://getcomposer.org/doc/03-cli.md#require
You may help --no-update key, but I'm not sure
Related
In recent days, it has become impossible to update the modules. I receive an error such as "this is not a valid module name".
Is it possible to manually update the modules by retrieving the latest files from Github? I tried to replace the files with those of the latest version but, it doesn't change anything at all.
I precise that I try to update official modules that are pre-installed in Prestashop.
Yes you can do this.
Grab the moduble from GitHub, wrap the whole module (the ps_xxxxxx directory) in a zip file then install the module from the admin interface.
Don't replace the files manually by using the filesystem (or at least try not to).
If you replace the modules in the modules directory you won't trigger the module "install" method, so if the new version needs some initialization it won't work properly.
EDIT:
Some modules have dependencies, for example ps_facetedsearch will require you to install composer and run 'composer install --no-dev' before you can pack it into a zip.
Alternatively you can get a json list of native prestashop modules here (replace [VERSION] with the version of prestashop you want, ex 1.7.6.4) :
https://api-addons.prestashop.com/?format=json&iso_lang=en&iso_code=all&version=[VERSION]&method=listing&action=native
Then you can download the module with its id with this URL (replace [VERSION] and [MODULE_ID] :
https://api-addons.prestashop.com/?format=json&iso_lang=en&iso_code=EN&version=[VERSION]&method=module&id_module=[MODULE_ID]
I am using rn-diff to upgrade react-native version for my app. Sometimes, the project.pbxproj is updated to contain some new dependencies or updates to the existing dependencies. What is the recommended way to update this file? I don't think that I can just copy and paste the changes shown in the diff because it may create some duplicates or create some conflicting entries in the file.
For example, below link contains changes made to the project.pbxproj file while changing from version 0.54.4 to 0.55.0. There are a lot changes to the project.pbxproj file and I am not sure if I am supposed to copy them over or I should rather be updating some dependencies myself in Xcode.
https://github.com/ncuillery/rn-diff/compare/rn-0.54.4...rn-0.55.0
In such cases I'm usually sad that I need to do this terrible thing ;)
But being serious: sadly going through RN Diff is like the very best thing that you can do now (unless you have NOT detached Expo.io but then you wouldn't probably ask here). So basically you go through each change that happened between your version and version to which you want to update and copy paste the changes in these files. As rarely you can apply patches (because your project file will be so different that there is no way that it will work out correctly).
My way of doing it is:
- see what changed
- see code block next to it, that is somehow easy to find out in my code (like some block of code that has unique ID + few properties around e.g. can be some native modules that are always there like TEXT or View or whatever, something which is always in RN)
- find the same element in my code and paste the new code above / below that code that was the same
Rinse and repeat
Please take a look at Upgrading to new React Native versions for upgrading your react native version!
Also if you want to update all of your dependencies, you can:
npm i -g npm-check-updates
ncu -u
npm install
And there is a library called npm-check-updates which:
Find newer versions of package dependencies than what your package.json or bower.json allows!
Some modules can be auto-updated in backoffice by clicking the update button. However if the module is from an other source than prestashop itself (e.g. github) the module needs - afaik - to be updated manually.
So how should one handle updates?
Download ZIP and
unzip it over the corresponding modules folder (/modules/acme/)
unzip and rsync it to /modules/acme (rsync -trv /tmp/acme /modules)
Same as 2 but with --delete
Delete the folder completely and unzip the new one in place like rm -rf /modules/acme and cp -a /tmp/acme /modules/acme
Others ...
Side note: what about the config.xml and possibly other generated files?
Same applies for theme updates, how to handle these?
Concerning current version Prestashop 1.7+.
If the module upgrade is made correctly (you can check if module version is updated in main module class constructor and uses upgrade scripts in upgrades folder and files inside the module) you can unzip over it. Then visit the modules list page in backend and module upgrade will run. config.xml is auto (re)generated and used only for optimizing module list loading in the same backend page - it has no effect on module behaviour itself.
For themes you can also just unzip over the last one.
When I am in doubt with any upgrades I make a development copy of the store and do upgrades there first and see if everything is ok then do upgrades on live instance.
You can perform the upgrade automatically with this free module
https://www.prestashop.com/forums/topic/820013-migrate-or-upgrade-prestashop-16-or-other-versions-to-17-%E2%80%93-free-module/
Hope it helps
I've found this on github that shows how to add github login to the accounts. https://github.com/Jabbslad/accounts-github
Instead of installing the package with "mrt add accounts-github", I'm downloading the sources, and trying to make them work with a simple app. The goal of this is to make a few changes to the code to understand how it works and finally make my own extension to accounts.
But I get errors "Cannot read property 'github' of undefined at app/accounts-github/github_common.js:1:36".
Thx for your help.
Because you added the package yourself you need to ensure the dependencies are also installed. You can find the dependencies in package.js
If you want to make the package from scratch ensure you also use a package in your meteor app. This means that you put your stuff in a directory called accounts-github in a directory called packages in the root directory of your meteor app.
You can also add these dependencies in yourself if you don't want to use a package:
meteor add accounts-base
meteor add accounts-oauth2-helper
meteor add http
Some dependencies should be in with meteor (i.e templating)
So the problem was the git for accounts-github was not updated with the latest evolutions from meteor. So I replaced "Meteor.accounts" with "Accounts" in all files and now it works.
I'm a totally new to ruby and rbenv, but I'm trying to get this 'bwoken' app working with rbenv.
This is bwoken, it's for iOS UIAutomation testing:
https://github.com/bendyworks/bwoken
My question is how do I add hooks for rbenv?
It says:
Ensure your after_cd_bundler rvm hook is enabled:
$ chmod u+x ~/.rvm/hooks/after_cd_bundler
Then, add the following line to your Rakefile:
Ok, so I see comments in the version history here
https://github.com/sstephenson/rbenv
saying this:
Added /usr/lib/rbenv/hooks to the plugin hook search path.
Added /usr/local/etc/rbenv.d to the list of directories searched for rbenv hooks.
The problem is what is the original default place for adding the hook? They don't mention it anywhere. Where is the correct place to put it?
For rbenv you'd have to use a dot (.) file like .rbenv_version. The plugin talks configuration in a rvm context. Both are different ways of having multiple ruby version on the same system.