mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-09-02 10:01:11 +02:00
44958: vcs_info quilt: Avoid forks
This commit is contained in:
parent
cc3983ee58
commit
98f8a8a980
3 changed files with 12 additions and 5 deletions
|
@ -1,5 +1,8 @@
|
||||||
2019-11-30 Daniel Shahaf <d.s@daniel.shahaf.name>
|
2019-11-30 Daniel Shahaf <d.s@daniel.shahaf.name>
|
||||||
|
|
||||||
|
* 44958: Functions/VCS_Info/VCS_INFO_quilt, README: vcs_info
|
||||||
|
quilt: Avoid forks
|
||||||
|
|
||||||
* 44945: Functions/VCS_Info/Backends/VCS_INFO_detect_git:
|
* 44945: Functions/VCS_Info/Backends/VCS_INFO_detect_git:
|
||||||
vcs_info git: Optimize detection by running fewer external
|
vcs_info git: Optimize detection by running fewer external
|
||||||
commands.
|
commands.
|
||||||
|
|
|
@ -78,7 +78,7 @@ function VCS_INFO_quilt-dirfind() {
|
||||||
VCS_INFO_bydir_detect ${dir}
|
VCS_INFO_bydir_detect ${dir}
|
||||||
ret=$?
|
ret=$?
|
||||||
vcs_comm[detect_need_file]=${oldfile}
|
vcs_comm[detect_need_file]=${oldfile}
|
||||||
printf '%s' ${vcs_comm[basedir]}
|
REPLY=${vcs_comm[basedir]}
|
||||||
vcs_comm[basedir]="${olddir}"
|
vcs_comm[basedir]="${olddir}"
|
||||||
return ${ret}
|
return ${ret}
|
||||||
}
|
}
|
||||||
|
@ -113,8 +113,8 @@ function VCS_INFO_quilt-patch2subject() {
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
pc="$(VCS_INFO_quilt-dirfind .pc .version)"
|
VCS_INFO_quilt-dirfind .pc .version
|
||||||
ret=$?
|
ret=$? pc=$REPLY
|
||||||
if (( ret == 0 )); then
|
if (( ret == 0 )); then
|
||||||
[[ ${quiltmode} == 'standalone' ]] && root=${pc}
|
[[ ${quiltmode} == 'standalone' ]] && root=${pc}
|
||||||
pc=${pc}/.pc
|
pc=${pc}/.pc
|
||||||
|
@ -138,8 +138,8 @@ function VCS_INFO_quilt-patch2subject() {
|
||||||
zstyle -s "${context}" quilt-patch-dir patches || patches="${QUILT_PATCHES}"
|
zstyle -s "${context}" quilt-patch-dir patches || patches="${QUILT_PATCHES}"
|
||||||
if [[ "${patches}" != /* ]]; then
|
if [[ "${patches}" != /* ]]; then
|
||||||
tmp=${patches:-patches}
|
tmp=${patches:-patches}
|
||||||
patches="$(VCS_INFO_quilt-dirfind "${tmp}")"
|
VCS_INFO_quilt-dirfind "${tmp}"
|
||||||
ret=$?
|
ret=$? patches=$REPLY
|
||||||
(( ret )) && return ${ret}
|
(( ret )) && return ${ret}
|
||||||
patches=${patches}/${tmp}
|
patches=${patches}/${tmp}
|
||||||
else
|
else
|
||||||
|
|
4
README
4
README
|
@ -49,6 +49,10 @@ The behaviour of :h has similarly changed.
|
||||||
The behaviour has also changed in forms such as ${foo:t2) and *(:t2),
|
The behaviour has also changed in forms such as ${foo:t2) and *(:t2),
|
||||||
but in those cases the previous behaviour was not meaningful.
|
but in those cases the previous behaviour was not meaningful.
|
||||||
|
|
||||||
|
The vcs_info function VCS_INFO_quilt-dirfind now returns a string value
|
||||||
|
by setting $REPLY. Previously it printed the value to standard output.
|
||||||
|
This only affects you if you override that function in your dotfiles.
|
||||||
|
|
||||||
Incompatibilities between 5.6.2 and 5.7.1
|
Incompatibilities between 5.6.2 and 5.7.1
|
||||||
-----------------------------------------
|
-----------------------------------------
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue