Fossil Wrapper

Check-in [eb6ae3b1a6]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:deleted redundant `show' interceptor and defined a new alias `s' to `changes --differ' which does exactly the same thing.
Timelines: family | ancestors | descendants | both | dresden
Files: files | file ages | folders
SHA1: eb6ae3b1a676f52bf7a98473a1cc85efd0389cf5
User & Date: j 2019-06-25 12:16:29
Context
2019-07-05
16:50
one bug and one regression less. check-in: 6933053d49 user: j tags: dresden
2019-06-25
12:16
deleted redundant `show' interceptor and defined a new alias `s' to `changes --differ' which does exactly the same thing. check-in: eb6ae3b1a6 user: j tags: dresden
2019-05-21
17:48
minor adjustments. check-in: 5a7ab09561 user: j tags: dresden
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to fsl.

114
115
116
117
118
119
120

121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
    alias  f      {finfo}
    alias  fb     {finfo -b}
    alias  fi     {finfo}
    alias  flog   {finfo}
    alias  heads  leaves;       # for hg refugees
    alias  log    {timeline -t ci}
    alias  not    {extras --dotfiles --ignore {}}

    alias  t      {timeline -t ci}
    alias  ticks  {ticket show 1}
    alias  time   {timeline}

    # -- Filters:

    filter status {
      add
      addremove
      changes
      info
      redo
      rm
      search
      status
      undo
      up
    } {
        lassign [split [string trim $line]] status
        switch -regexp $status {
            MERGED_WITH { coloured  purple $line }
            UPDATED_BY_MERGE { coloured  blue $line }
            ADDED       { coloured   green $line }
            EDITED      { coloured    blue $line }
            EXTRA       { coloured magenta $line }
            DELETED     { coloured     red $line }
            IGNORED     { coloured  yellow $line }
            MISSING     { coloured    cyan $line }
            UPDATE      { coloured     red $line }
            REMOVE      { coloured    blue $line }
            UNDO        { coloured    blue $line }
            REDO        { coloured    red $line }
            NEW         { coloured    magenta $line }
            RENAMED     { coloured    green $line }
            ^(checkout|parent|merged-(from|into)): {
               set date_rx {([a-f\d]{40} )(\d{4}-\d{2}-\d{2})}
               set artifact_rx {([a-f\d]{4})}
               regsub $date_rx     $line \\1[coloured blue \\2] line
               regsub $artifact_rx $line [coloured red \\1]
            }
            tags: {







>




















|
|
|
|
|
|
|
|
|
|
|
|
|
|







114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
    alias  f      {finfo}
    alias  fb     {finfo -b}
    alias  fi     {finfo}
    alias  flog   {finfo}
    alias  heads  leaves;       # for hg refugees
    alias  log    {timeline -t ci}
    alias  not    {extras --dotfiles --ignore {}}
    alias  s      {changes --differ}     ;# instead of redundandt `show' interceptor...
    alias  t      {timeline -t ci}
    alias  ticks  {ticket show 1}
    alias  time   {timeline}

    # -- Filters:

    filter status {
      add
      addremove
      changes
      info
      redo
      rm
      search
      status
      undo
      up
    } {
        lassign [split [string trim $line]] status
        switch -regexp $status {
            MERGED_WITH      { coloured  purple $line }
            UPDATED_BY_MERGE { coloured    blue $line }
            ADDED            { coloured   green $line }
            EDITED           { coloured    blue $line }
            EXTRA            { coloured magenta $line }
            DELETED          { coloured     red $line }
            IGNORED          { coloured  yellow $line }
            MISSING          { coloured    cyan $line }
            UPDATE           { coloured     red $line }
            REMOVE           { coloured    blue $line }
            UNDO             { coloured    blue $line }
            REDO             { coloured     red $line }
            NEW              { coloured magenta $line }
            RENAMED          { coloured   green $line }
            ^(checkout|parent|merged-(from|into)): {
               set date_rx {([a-f\d]{40} )(\d{4}-\d{2}-\d{2})}
               set artifact_rx {([a-f\d]{4})}
               regsub $date_rx     $line \\1[coloured blue \\2] line
               regsub $artifact_rx $line [coloured red \\1]
            }
            tags: {
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
               exit 1
            }
         }
      } 
   } else { return $params }
}

interceptor s:show {
# ------------------------------------------------------------------------
# Provide repository status information the hg/svn way. 
# ------------------------------------------------------------------------
   set afilter ::config::fslrc::status

   if {[catch {exec fossil changes} chrep]} {
      puts "$chrep"
      exit 1
   } else { set chrep [split $chrep \n] }

   foreach line "$chrep" {
      filter_with $afilter "$line"
      puts ""
   }

   if {[catch {exec fossil extras} exrep]} {
      puts "$exrep"
      exit 1
   } else { set exrep [split $exrep \n] }

   foreach line $exrep {
      set line "EXTRA      $line"
      filter_with $afilter "$line"
      puts ""
   }
}

interceptor w:wrapper {
# ------------------------------------------------------------------------
# This interceptor provides a compilation of the current aliases, filters,
# and interceptors.
# ------------------------------------------------------------------------
    # undo `span' expansion of the interceptors for this report
    # (admittedly, this is a bit stupid...). first, pad the list with







<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<







862
863
864
865
866
867
868




























869
870
871
872
873
874
875
               exit 1
            }
         }
      } 
   } else { return $params }
}





























interceptor w:wrapper {
# ------------------------------------------------------------------------
# This interceptor provides a compilation of the current aliases, filters,
# and interceptors.
# ------------------------------------------------------------------------
    # undo `span' expansion of the interceptors for this report
    # (admittedly, this is a bit stupid...). first, pad the list with