Testing tangled. Original: https://github.com/j6t/gitk

format-patch version #2

open opened by ilyagr.bsky.social targeting master
Labels

None yet.

Participants 1
AT URI
at://did:plc:jp6rly3c67o3zlwarw2ttafu/sh.tangled.repo.pull/3lvhyrlxh5222
+35 -17
Interdiff #0 โ†’ #1
+35 -17
gitk
··· 1903 global otherrefids idotherrefs mainhead mainheadid 1904 global selecthead selectheadid 1905 global hideremotes 1906 - global hidecustomrefs 1907 global tclencoding 1908 1909 foreach v {tagids idtags headids idheads otherrefids idotherrefs} { ··· 1940 set tagids($name) $id 1941 lappend idtags($id) $name 1942 } else { 1943 - if {$hidecustomrefs} { 1944 - if {![string match "stash" $ref] || 1945 - ![string match "replace/*" $ref]} continue 1946 } 1947 - set otherrefids($name) $id 1948 - lappend idotherrefs($id) $name 1949 } 1950 } 1951 catch {close $refd} ··· 11701 global NS maxwidth maxgraphpct showneartags showlocalchanges 11702 global tabstop wrapcomment wrapdefault limitdiffs 11703 global autocopy autoselect autosellen extdifftool perfile_attrs 11704 - global hideremotes hidecustomrefs want_ttk have_ttk maxrefs web_browser 11705 11706 set page [create_prefs_page $notebook.general] 11707 ··· 11721 ${NS}::checkbutton $page.hideremotes -text [mc "Hide remote refs"] \ 11722 -variable hideremotes 11723 grid x $page.hideremotes -sticky w 11724 - ${NS}::checkbutton $page.hidecustomrefs -text [mc "Hide custom refs"] \ 11725 - -variable hidecustomrefs 11726 - grid x $page.hidecustomrefs -sticky w 11727 11728 ${NS}::checkbutton $page.autocopy -text [mc "Copy commit ID to clipboard"] \ 11729 -variable autocopy ··· 11871 global oldprefs prefstop showneartags showlocalchanges 11872 global uicolor bgcolor fgcolor ctext diffcolors selectbgcolor markbgcolor 11873 global tabstop limitdiffs autoselect autosellen extdifftool perfile_attrs 11874 - global hideremotes hidecustomrefs want_ttk have_ttk wrapcomment wrapdefault 11875 11876 set top .gitkprefs 11877 set prefstop $top ··· 11880 return 11881 } 11882 foreach v {maxwidth maxgraphpct showneartags showlocalchanges \ 11883 - limitdiffs tabstop perfile_attrs hideremotes hidecustomrefs \ 11884 want_ttk wrapcomment wrapdefault} { 11885 set oldprefs($v) [set $v] 11886 } ··· 12007 global oldprefs prefstop 12008 12009 foreach v {maxwidth maxgraphpct showneartags showlocalchanges \ 12010 - limitdiffs tabstop perfile_attrs hideremotes hidecustomrefs \ 12011 want_ttk wrapcomment wrapdefault} { 12012 global $v 12013 set $v $oldprefs($v) ··· 12022 global oldprefs prefstop showneartags showlocalchanges 12023 global fontpref mainfont textfont uifont 12024 global limitdiffs treediffs perfile_attrs 12025 - global hideremotes hidecustomrefs wrapcomment wrapdefault 12026 global ctext 12027 12028 catch {destroy $prefstop} ··· 12069 $limitdiffs != $oldprefs(limitdiffs)} { 12070 reselectline 12071 } 12072 - if {$hideremotes != $oldprefs(hideremotes) || $hidecustomrefs != $oldprefs(hidecustomrefs)} { 12073 rereadrefs 12074 } 12075 if {$wrapcomment != $oldprefs(wrapcomment)} { ··· 12446 return $tcl_enc 12447 } 12448 12449 ## For msgcat loading, first locate the installation location. 12450 if { [info exists ::env(GITK_MSGSDIR)] } { 12451 ## Msgsdir was manually set in the environment. ··· 12549 set wrapdefault "none" 12550 set showneartags 1 12551 set hideremotes 0 12552 - set hidecustomrefs 0 12553 set maxrefs 20 12554 set visiblerefs {"master"} 12555 set maxlinelen 200 ··· 12656 mainfont textfont uifont tabstop findmergefiles maxgraphpct maxwidth 12657 cmitmode wrapcomment wrapdefault autocopy autoselect autosellen 12658 showneartags maxrefs visiblerefs 12659 - hideremotes hidecustomrefs showlocalchanges datetimeformat limitdiffs uicolor want_ttk 12660 bgcolor fgcolor uifgcolor uifgdisabledcolor colors diffcolors mergecolors 12661 markbgcolor diffcontext selectbgcolor foundbgcolor currentsearchhitbgcolor 12662 extdifftool perfile_attrs headbgcolor headfgcolor headoutlinecolor
··· 1903 global otherrefids idotherrefs mainhead mainheadid 1904 global selecthead selectheadid 1905 global hideremotes 1906 global tclencoding 1907 1908 foreach v {tagids idtags headids idheads otherrefids idotherrefs} { ··· 1939 set tagids($name) $id 1940 lappend idtags($id) $name 1941 } else { 1942 + if [is_other_ref_visible $name] { 1943 + set otherrefids($name) $id 1944 + lappend idotherrefs($id) $name 1945 } 1946 } 1947 } 1948 catch {close $refd} ··· 11698 global NS maxwidth maxgraphpct showneartags showlocalchanges 11699 global tabstop wrapcomment wrapdefault limitdiffs 11700 global autocopy autoselect autosellen extdifftool perfile_attrs 11701 + global hideremotes refstohide want_ttk have_ttk maxrefs web_browser 11702 11703 set page [create_prefs_page $notebook.general] 11704 ··· 11718 ${NS}::checkbutton $page.hideremotes -text [mc "Hide remote refs"] \ 11719 -variable hideremotes 11720 grid x $page.hideremotes -sticky w 11721 + 11722 + ${NS}::entry $page.refstohide -textvariable refstohide 11723 + ${NS}::frame $page.refstohidef 11724 + ${NS}::label $page.refstohidef.l -text [mc "Refs to hide (space-separated)" ] 11725 + pack $page.refstohidef.l -side left 11726 + pack configure $page.refstohidef.l -padx 10 11727 + grid x $page.refstohidef $page.refstohide -sticky ew 11728 11729 ${NS}::checkbutton $page.autocopy -text [mc "Copy commit ID to clipboard"] \ 11730 -variable autocopy ··· 11872 global oldprefs prefstop showneartags showlocalchanges 11873 global uicolor bgcolor fgcolor ctext diffcolors selectbgcolor markbgcolor 11874 global tabstop limitdiffs autoselect autosellen extdifftool perfile_attrs 11875 + global hideremotes refstohide want_ttk have_ttk wrapcomment wrapdefault 11876 11877 set top .gitkprefs 11878 set prefstop $top ··· 11881 return 11882 } 11883 foreach v {maxwidth maxgraphpct showneartags showlocalchanges \ 11884 + limitdiffs tabstop perfile_attrs hideremotes refstohide \ 11885 want_ttk wrapcomment wrapdefault} { 11886 set oldprefs($v) [set $v] 11887 } ··· 12008 global oldprefs prefstop 12009 12010 foreach v {maxwidth maxgraphpct showneartags showlocalchanges \ 12011 + limitdiffs tabstop perfile_attrs hideremotes refstohide \ 12012 want_ttk wrapcomment wrapdefault} { 12013 global $v 12014 set $v $oldprefs($v) ··· 12023 global oldprefs prefstop showneartags showlocalchanges 12024 global fontpref mainfont textfont uifont 12025 global limitdiffs treediffs perfile_attrs 12026 + global hideremotes refstohide wrapcomment wrapdefault 12027 global ctext 12028 12029 catch {destroy $prefstop} ··· 12070 $limitdiffs != $oldprefs(limitdiffs)} { 12071 reselectline 12072 } 12073 + if {$hideremotes != $oldprefs(hideremotes) || $refstohide != $oldprefs(refstohide)} { 12074 rereadrefs 12075 } 12076 if {$wrapcomment != $oldprefs(wrapcomment)} { ··· 12447 return $tcl_enc 12448 } 12449 12450 + proc is_other_ref_visible {ref} { 12451 + global refstohide 12452 + 12453 + if {$refstohide eq {}} { 12454 + return 1 12455 + } 12456 + 12457 + foreach pat [split $refstohide " "] { 12458 + if {$pat eq {}} continue 12459 + if {[string match $pat $ref]} { 12460 + return 0 12461 + } 12462 + } 12463 + 12464 + return 1 12465 + } 12466 + 12467 ## For msgcat loading, first locate the installation location. 12468 if { [info exists ::env(GITK_MSGSDIR)] } { 12469 ## Msgsdir was manually set in the environment. ··· 12567 set wrapdefault "none" 12568 set showneartags 1 12569 set hideremotes 0 12570 + set refstohide "" 12571 set maxrefs 20 12572 set visiblerefs {"master"} 12573 set maxlinelen 200 ··· 12674 mainfont textfont uifont tabstop findmergefiles maxgraphpct maxwidth 12675 cmitmode wrapcomment wrapdefault autocopy autoselect autosellen 12676 showneartags maxrefs visiblerefs 12677 + hideremotes refstohide showlocalchanges datetimeformat limitdiffs uicolor want_ttk 12678 bgcolor fgcolor uifgcolor uifgdisabledcolor colors diffcolors mergecolors 12679 markbgcolor diffcontext selectbgcolor foundbgcolor currentsearchhitbgcolor 12680 extdifftool perfile_attrs headbgcolor headfgcolor headoutlinecolor

Submissions

sign up or login to add to the discussion
ilyagr.bsky.social submitted #1
1 commit
expand
2441e19d
gitk: Add user preference to hide specific references
merge conflicts detected
expand
  • gitk:1939
ilyagr.bsky.social submitted #0
1 commit
expand
4a4a5125
gitk: Add user preference to hide custom references