Commit Graph

42 Commits

Author SHA1 Message Date
Dan McGee 869e81e1cf This commit looks much more monumental than it is. Almost all just #include
reordering and adding ones that were forgotten (noticed when trying to
compile after reordering).

* Updated the HACKING file to include information on #include usage.
* print -> vprint in "making dir" function in pactest.
2007-03-05 22:13:33 +00:00
Dan McGee e24c22e308 * A little more hacking with wchar_t output, but nothing really changed in
it. Eventually we'll make progress.
* Rewrote the _alpm_splitdep function to behave more like all our other
  function calls. Use heap instead of stack allocation for the depend struct,
  so now it needs to be freed by the caller.
2007-03-03 09:43:16 +00:00
Aaron Griffin 7f5dada885 Big commit this time:
* Moved entirely to alpm_pkg_get_* accessors, to read data on demand
* Mostly removed the INFRQ_ parameters from outside the be_files backend (making
  the backend more extensible in the long run)
* packages created from _alpm_db_scan now have the db and origin set (making
  accessors actually work for these packages)
* removed _alpm_db_ensure_pkgcache

* totally revamped the _alpm_checkconflicts function, making it cleaner and
  easier to read (and thus fix in the long run) - maintainable code ftw
  NOTE: feel free to rename the functions... I couldn't think of anything better

* removed an extra loop in sync.c:find_replacements - no sense in looping over
  an entire DB while strcmp'ing the name, when we have get_pkgfromcache

Other:
* package struct "license" -> "licenses"
* Created _alpm_sync_find (duplicate code in some places, find_pkginsync
* Minor const correctness changes along the way
* fixed a couple extra '/' pathing issues (non-issues really)
* removed a duplicate pkg_cmp function
2007-03-03 08:13:59 +00:00
Aaron Griffin d584d8c068 * Modified the handling and output w.r.t. IgnorePkg entries. -Sy always ignores
these packages, but -S explicitly asks for confirmation.
2007-02-23 02:10:56 +00:00
Aaron Griffin 37a3f26d2a * Forgot the second printf in the last commit 2007-02-22 04:46:34 +00:00
Aaron Griffin 3b95de655b * Using positional params (POSIX compliant, not C standard) for printfs that
require a lot of duplicates - this may or may not be a good idea with regards
  to portability, but we'll see
2007-02-22 04:32:09 +00:00
Aaron Griffin 92ad556512 * A whole mess of backup changes
- the code should be clearer, more organized, commented, and have worthwhile
    variable names now
  - proactive backup=()s now work.  That is, adding a file to a backup array
    does what it should on the upgrade to that package, no longer forcing you to
    wait a full upgrade cycle for it to take effect
* ldconfig was being run twice on an upgrade operation - fixed
* fixed another pm_fprintf/printf output corruption with the progress bars
* refactored some duplicate code for adjusting 'requiredby' lists
* Added config.rpath to .cvsignore
2007-02-17 08:55:05 +00:00
Dan McGee c557fa589d * Updated Italian translation
* Updated pot translation templates
* Located culprit of progress bar moving when unicode characters are used,
  added a TODO note about it
* Removed '(target)' string from the sync.c error message, just like we did
  from add.c yesterday
* Updated my TODO
2007-02-14 19:35:41 +00:00
Dan McGee cd34ced4ad * strlen -> mbstowcs (multibyte str to wide char str) conversion where we
want the actual number of characters, not the number of bytes.
* Added a TODO to take care of later in scriptlet processing.
2007-02-14 15:54:35 +00:00
Aaron Griffin d8fd645c4c * Cleaned up direct pm_fprintf usage (move to MSG/ERR macros for now)
* Moved some stderr output to stdout
* Remove "RETRIEVE_LOCAL" trans event as libdownload handles local files
2007-02-09 16:02:01 +00:00
Dan McGee b67e10d6b3 * Hopefully fixed the download progres bar for real. We should no longer
have issues with crazy speeds being displayed.
* Minor string updates to remove unnecessary 1-off translations.
2007-02-08 20:44:47 +00:00
Aaron Griffin e3c7e92f10 * unified the progress bars (fill_progress function)
* fixed progress output (needs an fflush to move cursor properly)
* broke display_targets function out, to display a list of syncpkgs in
  preparation for a -Qu option
* added get_update_time function to deal with progress functions that shouldn't
  update too fast due to output redraw speeds
2007-02-04 01:36:45 +00:00
Dan McGee c35f713e75 * Refactored some functions to clean up variable declaration.
* Reduced magic number usage by fill_progress function (new).
* Some switch indent fixing.
* Remove use of log10 call.
2007-01-31 01:37:41 +00:00
Aaron Griffin db87c8f62e * copy and paste error, "resolving deps" -> "cleaning up"
Signed-off-by: Dan McGee <dpmcgee@gmail.com>
2007-01-26 01:34:26 +00:00
Aaron Griffin 1b61cc8c69 This mainly deals with code clarity- removing currently unneeded
optimizations in order to make the code much more readable and
type-checkable. Every enum in the library now has it's own type that
should be used instead of the generic 'unsigned char'. In addition,
several #define statements dealing with constants were converted to
enums.

Signed-off-by: Dan McGee <dpmcgee@gmail.com>
2007-01-24 03:02:53 +00:00
Aaron Griffin 6167017264 Preliminary checkin for alpm_list conversion
* renamed pmlist_t -> alpm_list_t
* made alpm_list_t a public type (alpm_list.h header)
* removed additional storage for registered DBs in pacman source
* some code cleanup
* removed duplicate (pm)list_display functions from pacman source
* misc code cleanup
2007-01-19 09:28:44 +00:00
Aaron Griffin 86b136bb59 Dan McGee <dpmcgee@gmail.com>
* Removed some unnecessary headers and library links
* Made things static if possible
* Cleaned up makefiles a bit
* Fixed some old comments in the code
* Fixed some errors the static code checker splint pointed out
* Backwards arguments in a memset call in _alpm_db_read (could have been worse)
* Other various small fixes

Other:
* Default to 80 columns when getcols cannot determine display width
* Removal of ._install as a valid install file in packages
2007-01-18 16:52:57 +00:00
Aaron Griffin 37ae56e140 * Fix a missing slash separator in printed uri 2006-12-29 17:07:34 +00:00
Aaron Griffin d8d8221556 Modified front end output routines to accept a "padding' setting, which pads any
statement with ' ' until the size of the terminal.  The rationale is that, when
a log message is emitted during progress bar display, the terminal is artifacted.
This prevents that messiness.
2006-12-22 07:11:20 +00:00
Aaron Griffin 5469177183 Removed global maxcols - it is looked up on the fly now, so the progress bar is
resized.  Also used ioctl in place of the COLUMNS env variable
2006-11-22 04:53:10 +00:00
Aaron Griffin aa1c0ba9f8 * repo-add script - to add entries to a db file directly from package data (no PKGBUILD)
* libalpm api changes - move from a _getinfo(p, WHAT_WE_WANT) scheme to a
  typesafe _get_what_we_want(p) scheme [not 100% complete yet]
* some const correctness changes
* removal of PM_* types in alpm.h in favor of the pm*_t types used throughout
  libalpm
2006-11-20 09:10:23 +00:00
Aaron Griffin fbf1aa6539 * Fixed some alpm_get_option calls (long params were used for C99 compliance,
but were used in error)
* Cleaned up some output newlines
* Added "local database is up to date" when no packages are upgraded
2006-11-02 02:29:10 +00:00
Aaron Griffin 22ce4a2a00 Added a newline upong progress completion - this was accidentally left out causing the second progress bar to overwrite the first 2006-11-01 22:20:03 +00:00
Aaron Griffin 5a8bbc99be Numerous changes:
*   Added 'ILoveCandy' support to all progress bars
*   Changed download callback with regards to libfetch libalpm changes
*   libfetch error output on failed sync
*   Misc others I may have forgot to name (check the diff, heh)
2006-10-31 06:41:42 +00:00
Aaron Griffin ac30eb2c1e Applied Frugalware patch from Christian Hamar alias krix <krics@linuxforum.hu>
for file-conflict progress bar
Also did some CVS cleanup, removing some of the autogenerated files that
shouldn't have been there
2006-10-15 23:54:43 +00:00
Aaron Griffin 3f27542156 Merged frugalware changes. Added a few other minor things too, but there's alot
to list.  The diff should show you 8)
2006-10-15 19:34:52 +00:00
Judd Vinet bb787e26ee first stage of i18n stuff from VMiklos 2006-05-15 02:19:57 +00:00
Aurelien Foret b868e02967 fixed indentation 2006-02-22 20:58:12 +00:00
Aurelien Foret 78ffd98701 fixed outputs when downloadonly flag is set (patch from VMiklos <vmiklos@frugalware.org>) 2006-02-22 20:39:24 +00:00
Aurelien Foret 59edbdd4cf code cleanup 2006-01-07 17:50:20 +00:00
Aurelien Foret f3a4197e34 code cleanup (mainly removed line spaces at the beginning of lines by tabulations) 2006-01-07 09:42:48 +00:00
Judd Vinet 96de3501ab patch from VMiklos - use PACKAGE_VERSION instead of PACMAN_VERSION 2006-01-02 19:55:35 +00:00
Aurelien Foret db0df44598 code cleanup 2006-01-02 13:26:30 +00:00
Judd Vinet 58c9d5d663 applied first try at sync conflict handling (VMiklos) plus a couple changes 2005-12-26 06:40:29 +00:00
Judd Vinet ff50305a02 improved the Replace question format a bit 2005-10-20 23:31:14 +00:00
Aurelien Foret 8f191f3b33 added a missing header file declaration 2005-10-10 20:42:48 +00:00
Judd Vinet a36ded25eb added conversation callback support for transactions 2005-10-09 06:09:57 +00:00
Aurelien Foret da79a41054 fixed cb_trans() prototype 2005-05-09 09:14:45 +00:00
Aurelien Foret 5a035d0b40 fixed a log message 2005-04-17 20:07:48 +00:00
Aurelien Foret e115a5829e - updated sync feature
- added 2 new transaction events
2005-04-13 19:59:04 +00:00
Aurelien Foret 3dc36aa0e1 sync with changes in alpm.h and new RESOLVEDEPS event 2005-04-02 20:31:40 +00:00
Aurelien Foret 0709c15543 Relocated log and transaction stuffs from pacman.c to log.c and trans.c 2005-03-19 09:00:40 +00:00