Warning, /office/skrooge/README.md is written in an unsupported language. File is not indexed.

0001 # A personal finances manager, powered by KDE
0002 
0003 <img src="https://skrooge.org/sites/skrooge.org/files/images/header1.png" title="Juk logo">
0004 
0005 Skrooge allows you to manage your personal finances, powered by [KDE](http://www.kde.org). Thanks to its many [features](https://skrooge.org/features), it is one of the most powerful way to enter, follow, and analyze your expenses.
0006 
0007 Based on its KDE foundations, Skrooge can run on many platforms, including of course linux, BSD, Solaris, but also on Mac OS, and possibly on Windows.
0008 
0009 Learn more about [skrooge.org](https://skrooge.org/).
0010 
0011 ## Features
0012 
0013 ### Import your accounts from many sources
0014 
0015 Skrooge is able to import transactions from many formats (AFB120, QIF, CSV, MT940, OFX, QFX).  
0016 For a more reach import, Skrooge is able to import documents from many applications ([KMYMONEY](https://kmymoney.org/), Microsoft Money, [GNUCASH](http://gnucash.org/), [GRISBI](http://fr.grisbi.org/), [HOMEBANK](http://homebank.free.fr/fr/index.php) and [MONEY MANAGER EX](https://www.moneymanagerex.org/)).
0017 
0018 And better, Skrooge is able to import directly transactions from all your banks web sites in one click.
0019 
0020 ### Reporting
0021 
0022 Build the graph you want to well undestand how your spend your money.  
0023 Have a look to the periodic reports (monthly, annually, …) to undestand the progress.  
0024 Have a quick look on the dashboard.  
0025 Skrooge is also able to give you advice based on your behavior.  
0026 
0027 ### Like in a web browser
0028 
0029 Several tabs to help you organize your work.  
0030 Bookmark your preferred reports, graphs, filters, pages, …
0031 
0032 ### Budget
0033 
0034 Budgeting isn’t about restriction. It’s about setting and reaching your goals. Skrooge can help you to manage your budgets by putting in places simples rules.
0035 
0036 ### Classical features
0037 
0038 Infinite categories levels.  
0039 Scheduled transactions.  
0040 Multi currencies.  
0041 Manage payees.
0042 
0043 ### Advanced features
0044 
0045 Infinite undo/redo (even after the file was closed !)  
0046 Mass update of transactions.  
0047 Automatically process transactions based on search conditions.  
0048 Instant filtering on transactions and reports.  
0049 Download of quotes.  
0050 Add all properties you want on all objets (transactions, accounts, categories, …) and including files (pdf, pictures, …).
0051 
0052 ### Track refund of your expenses
0053 
0054 Skrooge can help you to check that you have received the expected refund (e.g. medical).
0055 
0056 ## How to install it:
0057 
0058 More information here: [https://skrooge.org/download](https://skrooge.org/download)
0059 
0060 ## How to build it:
0061 
0062 ### Install prerequisits:
0063 
0064  - xsltproc
0065  - libgrantlee5-dev (>=5.0.0)
0066  - libsqlite3-dev (>=3.7.0)
0067  - libofx-dev 
0068  - libboost-dev 
0069  - qtscript5-dev
0070  - qttools5-dev
0071  - libqt5webkit5-dev  (If you want to build with WebKit. You must not activate the option SKG_WEBENGINE) (**Preferred and default**)
0072  - libqt5webengine5-dev (If you want to build with WebEngine. You must activate the option SKG_WEBKIT)
0073  - libqt5svg5-dev
0074  - libkf5coreaddons-dev
0075  - libkf5archive-dev
0076  - libkf5xmlgui-dev
0077  - libkf5wallet-dev
0078  - libkf5parts-dev
0079  - libkf5newstuff-dev
0080  - libkf5iconthemes-dev 
0081  - libkf5kdelibs4support-dev
0082  - libkf5notifyconfig-dev       
0083  - libkf5runner-dev  
0084  - plasma-framework-dev  
0085  - libkf5doctools-dev   
0086  - kgendesignerplugin 
0087  - libqca-qt5-2-dev 
0088  - libkf5activities-dev
0089  - kross-dev 
0090  - qtdeclarative5-dev
0091  - qtquickcontrols2-5-dev
0092  - libsqlcipher-dev
0093  - sqlcipher
0094  - kirigami2-dev
0095 
0096         
0097 #### Examples:
0098 
0099 On ubuntu:
0100 
0101     sudo apt-get install pkg-config build-essential cmake devscripts cdbs extra-cmake-modules kross-dev sqlite3 sqlcipher libsqlcipher-dev libgrantlee5-dev libsqlite3-dev libofx-dev libboost-dev xsltproc qtscript5-dev qttools5-dev libqt5webkit5-dev libqt5svg5-dev libkf5coreaddons-dev libkf5archive-dev libkf5xmlgui-dev libkf5activities-dev libkf5wallet-dev libkf5parts-dev libkf5newstuff-dev libkf5iconthemes-dev libkf5kdelibs4support-dev libkf5notifyconfig-dev libkf5runner-dev libkf5doctools-dev kgendesignerplugin libqca-qt5-2-dev qtbase5-private-dev qtquickcontrols2-5-dev kirigami2-dev libkf5plasma-dev qtwebengine5-dev qtdeclarative5-dev libqt5xmlpatterns5-dev
0102 
0103 ### Extract the archive, and enter the "skrooge" directory. Then run :
0104 
0105         mkdir build && cd build
0106         cmake .. -DCMAKE_INSTALL_PREFIX=[path to your KDE installation]
0107         make
0108 
0109 #### Examples:
0110 
0111 On ubuntu:
0112 
0113                 mkdir build && cd build
0114                 cmake .. -DCMAKE_INSTALL_PREFIX=`kf5-config --prefix` -DQT_PLUGIN_INSTALL_DIR=`kf5-config --qt-plugins` -DCMAKE_BUILD_TYPE=release -DCMAKE_EXPORT_COMPILE_COMMANDS=1 -DSKG_WEBENGINE=OFF -DSKG_BUILD_TEST=OFF -DSKG_DESIGNER=OFF 
0115                 make
0116                 
0117 
0118 On ubuntu (with ninja):
0119 
0120                 mkdir build && cd build
0121                                                                                                                                                                                                                                                                 release -DCMAKE_EXPORT_COMPILE_COMMANDS=1 -DSKG_WEBENGINE=OFF -DSKG_WEBKIT=ON -DSKG_BUILD_TEST=OFF -DSKG_DESIGNER=OFF 
0122                 make
0123         
0124         
0125 
0126 ### Prepare to run
0127 
0128         Skrooge uses plugins. By default, plugins are loaded from your system. It means that, if you have a local build of Skrooge and an other version of Skrooge installed on your system. The system version of plugins will be loaded.
0129         The easiest solution is to install your local build like this:
0130                 make install (as root)
0131                 
0132 #### Examples:
0133 
0134 On ubuntu:
0135 
0136     sudo make install 
0137 
0138 If you don't want to install Skrooge on your system, you will have to set many Qt and Kde environment variables before running skrooge. This is not easy to do.
0139 
0140 ### Run the test
0141 
0142     ctest
0143 
0144 #### Run skrooge
0145 
0146     /usr/bin/skrooge
0147     
0148 ## Other important thinks to remember
0149 
0150 ### For Static code analysis (scan-build)
0151 
0152     CXX=clang++ CC=clang scan-build -k cmake .. -DCMAKE_INSTALL_PREFIX=`kf5-config --prefix` -DQT_PLUGIN_INSTALL_DIR=`kf5-config --qt-plugins` -DCMAKE_BUILD_TYPE=profile
0153     make clean
0154     scan-build -k -o results make
0155 
0156 ### With sanitizer (-fno-omit-frame-pointer )
0157 
0158     cmake .. -DCMAKE_INSTALL_PREFIX=`kf5-config --prefix` -DCMAKE_BUILD_TYPE=profile -DECM_ENABLE_SANITIZERS='undefined,address,asan,ubsan'
0159     export ASAN_OPTIONS=detect_leaks=1
0160 
0161 ### With clazy
0162 
0163     export CXX="clazy"
0164     export CLAZY_CHECKS="level0,level1,level2"
0165     export CLAZY_FIXIT="fix-qlatin1string-allocations,fix-fromLatin1_fromUtf8-allocations,fix-fromCharPtrAllocations"
0166     cmake .. -DCMAKE_CXX_COMPILER=clazy -DCMAKE_INSTALL_PREFIX=`kf5-config --prefix` -DCMAKE_BUILD_TYPE=Debug
0167     
0168     make clean
0169     make -i > t.txt 2>&1
0170     cat t.txt | grep "warning:" | grep -v "ui_" | grep -v "moc_" | grep -v "_settings" |grep -v "/usr/include" | grep -v "FixIt failed" | grep -v ".moc:" | grep -v "/build/" | sort -u > warning_all.txt 
0171     cat warning_all.txt | grep -v "ctor-missing-parent-argument" | grep -v "clazy-copyable-polymorphic" | sort -u > warning.txt 
0172 
0173 ### With clazy-standalone
0174 
0175     cmake .. -DCMAKE_INSTALL_PREFIX=`kf5-config --prefix` -DCMAKE_BUILD_TYPE=release -DCMAKE_EXPORT_COMPILE_COMMANDS=1 
0176     make
0177     find . -name "*cpp" | xargs clazy-standalone -checks=level0,level1,level2 -p compile_commands.json > t.txt 2>&1
0178     cat t.txt | grep "warning:" | grep -v "ui_" | grep -v "moc_" | grep -v "_settings" |grep -v "/usr/include" | grep -v "FixIt failed" | sort -u > warning.txt
0179 
0180 ### clang-tidy
0181 
0182     run-clang-tidy.py -header-filter='.*' -checks=*,-fuchsia-*,-objc-*,-android-*,-abseil-*,-google-*,-misc-unused-parameters,-clang-diagnostic-error,-cppcoreguidelines-pro-type-member-init,-llvm-header-guard,-readability-inconsistent-declaration-parameter-name,-readability-redundant-member-init -fix > traces.txt
0183      
0184     cat traces.txt | grep warning  | grep -v ui_ | grep  -v /build/ | grep -v "clang-tidy -header" | sort -u > clangtidy.txt
0185 
0186 ### With coverity
0187 
0188     export PATH=~/Telechargements/cov-analysis-linux64-2022.6.0/bin/:$PATH
0189     make clean
0190     cov-build --dir cov-int make -j 4
0191     tar caf skrooge.bz2 cov-int
0192 
0193 ### iwyu
0194 
0195     iwyu_tool.py -p .
0196 
0197 ### Docker
0198 
0199     sudo docker build -t skrooge .
0200     sudo docker run -e DISPLAY=unix$DISPLAY -v /tmp/.X11-unix:/tmp/.X11-unix skrooge
0201 
0202 ### Flatpak
0203 
0204 [https://community.kde.org/Guidelines_and_HOWTOs/Flatpak]
0205 
0206 #### Build
0207 
0208     mkdir app repo
0209     flatpak install flathub org.kde.Platform//5.12
0210     flatpak install flathub org.kde.Sdk//5.12
0211     flatpak install flathub io.qt.qtwebkit.BaseApp//5.12
0212     flatpak-builder --ccache --repo=repo --subject="Build of skrooge `date`" skrooge org.kde.skrooge.json --force-clean
0213     
0214 #### Install
0215 
0216     flatpak uninstall org.kde.skrooge
0217     flatpak install skrooge org.kde.skrooge
0218     
0219 #### Run    
0220 
0221     flatpak run org.kde.skrooge
0222     
0223 #### Debug    
0224 
0225     flatpak run --command=sh --devel org.kde.skrooge
0226 
0227 ### Convert all logo in 100x100
0228 
0229     for x in /home/s/Developpements/skrooge/images/logos/*.png
0230     do
0231         convert $x -resize 100x100 $x
0232     done