diff --git a/migrating_to_2.0/commands.rst b/migrating_to_2.0/commands.rst index e63d6ff82ba..a0644d34914 100644 --- a/migrating_to_2.0/commands.rst +++ b/migrating_to_2.0/commands.rst @@ -20,6 +20,7 @@ Remember that in Conan 1.X you have to specify the build profile or activate the $ conan install . [--name=mylib] [--version=1.0] [-pr:b=build_profile] [-pr:h=host_profile] +In addition the ``--install-folder`` has been replaced with ``--output-folder``. You might need to provide both arguments in Conan 1.X as some legacy generated files (``conaninfo.txt``, ``conanbuildinfo.txt``, etc) are not affected by ``--output-folder``. conan create ^^^^^^^^^^^^ diff --git a/reference/conanfile/tools/scm/git.rst b/reference/conanfile/tools/scm/git.rst index 520fc034538..b9588f0de3c 100644 --- a/reference/conanfile/tools/scm/git.rst +++ b/reference/conanfile/tools/scm/git.rst @@ -40,6 +40,12 @@ get_remote_url() Obtains the URL of the ``remote`` git remote repository, with ``git remote -v`` +.. warning:: + + This method will get the output from ``git remote -v``. If you added tokens or credentials to the remote in the URL, they will be + exposed. Credentials shouldn't be added to git remotes definitions, but using a credentials manager or similar mechanism. + If you still want to use this approach, it is your responsibility to strip the credentials from the result. + commit_in_remote() ------------------ @@ -104,6 +110,14 @@ get_url_and_commit() .. code-block:: python def get_url_and_commit(self, remote="origin") + # returns a (url, commit) tuple + + +.. warning:: + + This method will get the output from ``git remote -v``. If you added tokens or credentials to the remote in the URL, they will be + exposed. Credentials shouldn't be added to git remotes definitions, but using a credentials manager or similar mechanism. + If you still want to use this approach, it is your responsibility to strip the credentials from the result. This is an advanced method, that returns both the current commit, and the remote repository url.