New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
proposing base_source_folder, and folders.root #10654
proposing base_source_folder, and folders.root #10654
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would try to make it a bit more self-explanatory because it is not easy to understand at all .
conans/model/layout.py
Outdated
|
||
def __repr__(self): | ||
return str(self.__dict__) | ||
|
||
def set_local(self, conanfile_folder, output_folder): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe set_base_folders
? I don't know why set_local
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also a docstring would be nice. It is not easy to understand the arguments and the sense they have.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is only called from local flow, never in the cache. I tried to convey that meaning. I can try to rename to something like set_local_base_folders()
and I will add docstring.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't know if "from where I call it" should be the thing naming the function rather than the thing that the function does.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Renamed the method, and added a bunch of docstrings and comments in b6971ba, please re-review and let me know
Co-authored-by: Luis Martinez <lasote@gmail.com>
* first approach. Big changes in Conf * Fixing errors * Fixing more tests * Deleted useless iteration * All the tests passing * Testing * Added items method * fixed rebased * Keeping old functions for backward compatibility * backward compatibility * Keeping indentation * Ordering methods and improved legacy logic * Added fixme * Reverted breaking changes * Added more complete test * Added more access Conf tests * Added docstring * Splitted string asserts * Added get/pop functions * Breaking refactor. Trying new structure * fixing tests * Changing tests * Fixed tests * Fixed Python 2.x problems * Removed useless layer of types * Fixed py2 * Fixed errors and added cast param to apply function to convert any type * Added TODO * Improved docstring * Fixed error * Update conans/model/conf.py Co-authored-by: James <james@conan.io> * Update conans/model/conf.py Co-authored-by: James <james@conan.io> * Added check_type and removed cast * Changed main structure. Now simpler and more powerful * Explicit default * Fixed error * Simplified compile options * Changed all the legacy conf getitem built-ins * Fixed test * Fixed bad type * Added more tests * More tests * Fix test for Python2 * Added more tests. Fixed corner-cases * Added one cli test and improved boolean conf UX * Moved str conveersion * Added one more mechanism to other smart conversion. Added more tests * Removed useless OR Co-authored-by: James <james@conan.io>
* Added custom versions and descriptions for components * Changed property to component_version. Backported to legacy PkgConfig
* WIP: Test failing * output_folder absolute only when existing * Fix test windows
* use absolute path * Update conans/test/integration/environment/test_env.py Co-authored-by: James <james@conan.io> * fix tests * fix test * fix win * fix win Co-authored-by: James <james@conan.io>
Co-authored-by: James <james@conan.io>
Changelog: Feature: Adding
self.base_source_folder
forexports_sources
explicit layouts.Changelog: Feature: Adding
root
to layout model to allow conanfile.py in subfolders.Docs: conan-io/docs#2418