Description:

With krep you can view a file. While viewing, you can set and change a filter for the file's content. You can use a regular expression as filter. If no file is given, krep gets its data from standard input.

Example: You want to search in /var/log/message for messages from Aug 30. So, you enter Aug 30 into krep, and it only shows lines containing this string. You see it is still too much, so you enter another key word you are looking for, say, syslog, and click on filter. Then, you will only get lines from /var/log/messages that contain as well "Aug 30" as "syslog".

If you want again more output, you can delete filtering lines and get again more lines displayed.
Last changelog:

10 years ago

0.1 - work
0.2 - read stdin in case no argument
0.3 - install in kde-directory, even if it is not /usr/local/kde
0.4 - react on file changes like tail -f
0.5 - "only show lines containing"
0.6 - ignore newline in regex field
0.7 - speed up by factor > 4
0.8 - allow more than 1 filter expression
0.81 - compile with GCC 4.1
0.82 - prompt the user for text input
1.1 - make it compile even if compiler is not permissive

arkascha

6 years ago

This is a nice start, since its purpose and abilities are clear, so thanks !

Gui applications can never become as crunchy and flexible as their cli counterparts, but they may help less experienced users to dig deeper into things and learn.
What puzzles me is the combination of a simplistic gui (as in "for less experienced") in combination with the use of regexs. So the niche for this application might be a offer good assistance in more complex filter patterns. For this it might make sense to use a more sophisticated regex editor/wizard. Maybe you could re-use something existing or get inspired by looking at some other apps constructing regexes.

Anyway, keep up the good work !

Report

C

thstaerk

6 years ago

thank you :) You understood what I wanted - bringing regex's to newbies. There are opportunities to improve, but I am taking steps slowly because I do not want to sacrifice simplicity :)

Thorsten

Report

Mte90

6 years ago

i get this error on compiling on aptosid with kde 4.6 and qt 4.7

root@aptosidbox:/home/mte90/Desktop/krep# cmake . && make && make install
-- The C compiler identification is GNU
-- The CXX compiler identification is GNU
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Looking for Q_WS_X11
-- Looking for Q_WS_X11 - found
-- Looking for Q_WS_WIN
-- Looking for Q_WS_WIN - not found.
-- Looking for Q_WS_QWS
-- Looking for Q_WS_QWS - not found.
-- Looking for Q_WS_MAC
-- Looking for Q_WS_MAC - not found.
-- Found Qt-Version 4.7.3 (using /usr/bin/qmake)
-- Looking for XOpenDisplay in /usr/lib/x86_64-linux-gnu/libX11.so;/usr/lib/x86_64-linux-gnu/libXext.so;/usr/lib/x86_64-linux-gnu/libXft.so;/usr/lib/x86_64-linux-gnu/libXau.so;/usr/lib/x86_64-linux-gnu/libXdmcp.so
-- Looking for XOpenDisplay in /usr/lib/x86_64-linux-gnu/libX11.so;/usr/lib/x86_64-linux-gnu/libXext.so;/usr/lib/x86_64-linux-gnu/libXft.so;/usr/lib/x86_64-linux-gnu/libXau.so;/usr/lib/x86_64-linux-gnu/libXdmcp.so - found
-- Looking for gethostbyname
-- Looking for gethostbyname - found
-- Looking for connect
-- Looking for connect - found
-- Looking for remove
-- Looking for remove - found
-- Looking for shmat
-- Looking for shmat - found
-- Looking for IceConnectionNumber in ICE
-- Looking for IceConnectionNumber in ICE - found
-- Found X11: /usr/lib/x86_64-linux-gnu/libX11.so
-- Looking for include files CMAKE_HAVE_PTHREAD_H
-- Looking for include files CMAKE_HAVE_PTHREAD_H - found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Looking for _POSIX_TIMERS
-- Looking for _POSIX_TIMERS - found
-- Found Automoc4: /usr/bin/automoc4
-- Found Perl: /usr/bin/perl
-- Found Phonon: /usr/include
-- Performing Test _OFFT_IS_64BIT
-- Performing Test _OFFT_IS_64BIT - Success
-- Performing Test HAVE_FPIE_SUPPORT
-- Performing Test HAVE_FPIE_SUPPORT - Success
-- Performing Test __KDE_HAVE_W_OVERLOADED_VIRTUAL
-- Performing Test __KDE_HAVE_W_OVERLOADED_VIRTUAL - Success
-- Performing Test __KDE_HAVE_GCC_VISIBILITY
-- Performing Test __KDE_HAVE_GCC_VISIBILITY - Success
-- Found KDE 4.6 include dir: /usr/include
-- Found KDE 4.6 library dir: /usr/lib
-- Found the KDE4 kconfig_compiler preprocessor: /usr/bin/kconfig_compiler
-- Found automoc4: /usr/bin/automoc4
-- Configuring done
-- Generating done
-- Build files have been written to: /home/mte90/Desktop/krep
Scanning dependencies of target krep_automoc
Generating krep.moc
[ 0%] Built target krep_automoc
[ 14%] Generating ui_krepui.h
[ 28%] Generating mainadaptor.cpp, mainadaptor.h
[ 42%] Generating mainadaptor.moc
Scanning dependencies of target krep
[ 57%] Building CXX object CMakeFiles/krep.dir/krep_automoc.o
[ 71%] Building CXX object CMakeFiles/krep.dir/main.o
[ 85%] Building CXX object CMakeFiles/krep.dir/krep.o
/home/mte90/Desktop/krep/krep.cpp: In member function ‘void krep::slotfilechanged()’:
/home/mte90/Desktop/krep/krep.cpp:138:52: error: taking address of temporary [-fpermissive]
make[2]: *** [CMakeFiles/krep.dir/krep.o] Error 1
make[1]: *** [CMakeFiles/krep.dir/all] Error 2
make: *** [all] Error 2

Report

C

thstaerk

6 years ago

I know this error and have a lot to say about it. In a hurry, just delete line 138 and 139 of krep.cpp,

thanks for becoming a fan

Thorsten

Report

skulptor

6 years ago

Qt uses value types for many data types, so you always get a copy of those returned from many functions. Because of reference counting, those copies are fast, though.

To change the cursor position, use QTextEdit::setTextCursor(). You can pass your own cursor positions, or the position returned from textCursor().

Report

C

thstaerk

4 years ago

hey Christoph, have you seen my kde-contextmenu that I derived from your favorites menu?

Report

C

thstaerk

6 years ago

I fixed this for you. The problem is described at http://doc.qt.nokia.com/4.7/qtextedit.html#textCursor - who in the world wants A COPY of the text cursor to be returned?

Anyway, fixed, please test :)

thanks for the report

Thorsten

Report

Mte90

6 years ago

thanks for the fix now compile :-)
when i like a software that it's useful i'm became a fan :-P

a suggestion for the program, but a dialog for choose the file to open in the gui it's possibile?

Report

C

thstaerk

6 years ago

yes that should not be a problem. However at the moment I am discovering myself as a packager (as openSUSE build service suddenly stops saying "set -fpermissive").

Report

C

thstaerk

6 years ago

ok I implemented your proposal in version 1.2. It is in svn, not yet packaged.

regards

Thorsten

Report

Mooz

10 years ago

Thorsten,
the use of regular expressions in you program beats the plain old crap grep!

Good work!!

ThX

Maybe i'm going to build some rpm packages for openSUSE soon.

Report

10 years ago

0.1 - work
0.2 - read stdin in case no argument
0.3 - install in kde-directory, even if it is not /usr/local/kde
0.4 - react on file changes like tail -f
0.5 - "only show lines containing"
0.6 - ignore newline in regex field
0.7 - speed up by factor > 4
0.8 - allow more than 1 filter expression
0.81 - compile with GCC 4.1
0.82 - prompt the user for text input
1.1 - make it compile even if compiler is not permissive

product-maker FraSMOG Sep 07 2011

product-maker 14 24

File (click to download) Version Description Filetype Packagetype License Downloads Date Filesize OCS-Install DL
Details
version
1.1
updated Sep 08 2011
added Dec 26 2006
downloads today
0
page views today 4