Commit Graph

454 Commits

Author SHA1 Message Date
mauro.giachero
30ad5a995d Fix '-s' command line switch.
The '-s' switch got broken, mainly because it used "leaking"
variables. Give it a proper interface, and use that.
Also, properly check for search failures.

Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-05-21 16:34:09 +00:00
mauro.giachero
9ee548f2c3 Refactor get_source() a bit.
Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-05-21 08:51:04 +00:00
mauro.giachero
1d47dfab92 Rework source checking.
David Spencer reported on the ML that the current sbopkg
behavior of checking the MD5 only just after the download
breaks some (bad) applications, like Google Earth, which
don't change the source file name on version upgrades.

This patch puts an additional check for existing sources,
so to workaround this issue (at the expense of extra MD5
checks for all other good applications). Moreover, add an
option to retry the download, which comes handy with the
aforementioned bad applications since otherwise the user had
to start the build twice (the first time he sees a failed
MD5 check and has the option to delete the downloaded file,
and the second time the source gets downloaded again).

Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-05-21 08:08:01 +00:00
mauro.giachero
50c293ff1e Fix queue processing.
Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-05-21 08:07:51 +00:00
mauro.giachero
da958c527d Improve file cleanup for search-related functions.
This patch revisits some cleanup path, and makes sure that
the temporary files are deleted where appropriate.

Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-05-21 08:07:40 +00:00
mauro.giachero
d8a74980be Cleanup gen_search_package().
This patch replaces some wrong 'continue' statements with
'return 0' (which is functionally equivalent on all call
sites), merging some of them at the end of the function.

Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-05-21 08:07:30 +00:00
mauro.giachero
a24462f13f Use return values to implement the jump back to the main menu.
sbopkg 'touch'es a file (sbopkg_return_main_menu) to track
that the user asked to jump back to the main menu from a
"deep" menu level (such as info_item).
This patch converts it to the usage of function return values,
which makes the code smaller and easier to read.

Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-05-21 08:07:19 +00:00
mauro.giachero
31ce00b3d1 Sanity check $SBOPKGTMP.
Since we do many file operations in $SBOPKGTMP, including
some 'rm -rf', check its content on startup to make sure no
user files are mistakenly in there.

Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-05-21 08:07:09 +00:00
mauro.giachero
bd057d45e4 Cleanup {edit,delete,pick}_local_{info,SlackBuild}() and more.
This patch removes some code duplication and modifies some
detail about the EDITOR, PAGER and HAS_NCURSES variables.

Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-05-21 08:06:57 +00:00
mauro.giachero
b4cef20b18 Add the museek-plus->museek+ rename.
Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-05-21 08:06:46 +00:00
chess.griffin
5da74910d6 enforce '.sboq.' extension to queuefiles; also, if argument passed at cli is the name of a queuefile and a package, ask user which one he wants to use 2009-05-20 12:51:16 +00:00
chess.griffin
c39e7e2b1b fix typo to man page 2009-05-18 19:40:28 +00:00
chess.griffin
cb8eb52669 update both man pages; these man pages might need more tweaking but there were a couple of things I had been wanting to fix/update in the meantime 2009-05-18 19:38:20 +00:00
chess.griffin
1fcce2efe8 update some of the items in /docs 2009-05-18 19:32:00 +00:00
mauro.giachero
6a186e9d8b New repository layout implementation.
This patch introduces a new repos.d directory containing
all the definitions of repository branches. This way the
supported repositories can be extended without modifying
the default configuration files, which causes problems on
version updates.
Thanks to Chess Griffin for his efforts in planning this
feature and reviewing the implementation.

Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-05-18 09:03:18 +00:00
chess.griffin
a125d260fc undo last commit; man pages were accidentally update 2009-05-16 05:00:01 +00:00
chess.griffin
30da6c2a1f update trunk ChangeLog.txt 2009-05-16 04:51:00 +00:00
chess.griffin
0a6d282289 tweak the output of the summary log 2009-05-16 04:26:32 +00:00
chess.griffin
2ced9364a4 do not show files that end in '~' in queue dir lister; when importing lines from a user queue, check and skip blank lines and comment lines; fix view_queue call when using 'Process' button in queue menu 2009-05-14 20:36:50 +00:00
chess.griffin
fe357d64e4 more process_queue cleanups 2009-05-14 19:47:23 +00:00
chess.griffin
6bd48b9f8a modify the log a bit; add some counters; move one more bit (the echos at end of build_package) to the caller; change the build/install dialog to a 'yes/no' dialog per Mauro's suggestion 2009-05-14 16:27:54 +00:00
chess.griffin
07c263c203 rework the whole process_queue and related functions; this patch attempts to properly handle certain items by the caller instead of in the called function; it also does away with the INSTALLPKGS and BUILDPKGS toggles; the logging is cleaned up and improved; and various other FIXMEs and tweaks are made along the way. 2009-05-14 14:06:44 +00:00
chess.griffin
0ff2ee1f91 try and fix svn revision propset on sbopkg; take 2 2009-05-12 19:28:15 +00:00
chess.griffin
ef23192fd2 try and fix svn revision propset on sbopkg 2009-05-12 19:27:44 +00:00
chess.griffin
516c681183 add support for new *.txz, *.tbz, and *.tlz Slackware package extensions. 2009-05-12 14:03:29 +00:00
mauro.giachero
99b16afbeb Fix a couple of "Build and Install" bugs.
Spotted and fixed by Chess Griffin.
2009-05-12 07:37:32 +00:00
chess.griffin
f6e81fa444 apply SVN propset to 50-default 2009-05-08 21:51:40 +00:00
mauro.giachero
3078f984fa Implement renames tracking using a configuration directory.
Modify the renames tracking so that, instead of a single
file, all the files of a renames.d directory are used (just
like udev and modprobe do).
This has several advantages:
- no more need to "mv sbopkg-renames.new sbopkg-renames"
- it's now easier to add custom renames that automatically
  "survive" version upgrades
and, last but not least, this is believed to be the correct
way to handle these things.

Many thanks are due to Robby Workman for proposing this
change and to Chess Griffin for implementing it.
2009-05-08 08:39:37 +00:00
mauro.giachero
91db815094 Fix package building by making two more variables global.
The giant cleanup broke package building by marking "too
many" variables as local. These two are actually used
elsewhere, so just make them global.

Thanks to Chess Griffin for this fix.
2009-05-07 10:14:30 +00:00
mauro.giachero
3ddf3a7067 Fix per-user SLACKVER setting.
If the user ever created a personal sbopkg.conf file not
containing the SLACKVER=... line, the old code would not
add it.
This patch fixes the code by removing the assignment if it
exists, and then unconditionally adding the new one at the
end.

Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-05-07 10:14:19 +00:00
mauro.giachero
449e2371a9 Fix local repo test.
This change got lost when resolving some merge conflict :-/.

Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-05-07 10:14:08 +00:00
mauro.giachero
3d98703b9d Do not unset SBOPKG_CONF at startup.
SBOPKG_CONF shouldn't be unset at startup, because we want
to be able to override the default config file name with it.

Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-05-07 10:13:54 +00:00
mauro.giachero
7fabdd8f97 'Nice' the build process.
Give a lower priority to the build process, so that sbopkg
becomes less a resource hog when left working in background.

Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-05-07 10:13:41 +00:00
chess.griffin
ea887535c4 undo last change; that was not the solution to why renames is not working 2009-05-06 18:26:10 +00:00
chess.griffin
ca03f902b0 minor fix to get_old_name call 2009-05-06 18:16:09 +00:00
mauro.giachero
e31680566e Implement configurable repository management and git support.
This patch makes the repository list a configurable item
inside sbopkg.conf.
With this new way to specify repositories, there's the
possibility of naming the tool able to sync the local copy
of the remote repository. Such feature has been then used to
implement the support of git-based repositories, much
common in the Slamd64 land.

Please note that the purpose of this patch is to provide a
more flexible fetching system. The additional repositories
must be careful in being conform to the SlackBuilds.org
structure, or sbopkg will fail with them.

Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-05-06 13:56:42 +00:00
chess.griffin
00c0bfe937 fix two minor issues with commits r533 and r539 2009-04-30 14:17:29 +00:00
mauro.giachero
d19fde901a Fix typo.
Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-04-30 07:46:26 +00:00
mauro.giachero
cb2dff127a Fix non-browsable 'games' due to " in slack-desc.
Thanks to slakmagik for this fix.
2009-04-29 14:35:37 +00:00
mauro.giachero
b599f398a3 Fix bug where "sbopkg -c -v local" showed a dialog.
Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-04-29 14:35:25 +00:00
mauro.giachero
66c52845b6 Properly quote $CWD.
$CWD stores the directory the user started sbopkg from.
We cannot make assumptions about it not containing spaces,
so proper quoting is needed.

Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-04-29 14:35:14 +00:00
mauro.giachero
42d33db44b Fix installed packages list not shown with no packages installed.
Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-04-29 14:35:04 +00:00
mauro.giachero
82acea8919 Add new rename: GNOME-Colors -> gnome-colors
Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-04-29 14:34:55 +00:00
mauro.giachero
8252d0d7c6 Let sbopkg learn about the acroread -> adobe-reader rename.
Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-04-29 14:34:43 +00:00
mauro.giachero
5beff37f6e Remove stale 'find' call.
This is a call I forgot to remove when the new updates code
went in (r333). There were no functional changes due to this,
but slowed down the updates by a perceivable amount.

Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-04-29 14:34:34 +00:00
mauro.giachero
28b98e1beb Apply a huge cleanup patch.
This patch touches almost every part of sbopkg, making
it more readable, manageable and less bug-prone.
Working on this already let us spot several bugs, and
will ease further development and debugging efforts.

This is the result of a lot of patient team work, for
which Chess, slakmagik and I should be equally credited.

Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-04-29 14:34:25 +00:00
chess.griffin
672dd00b2c modify HACKING 2009-03-26 12:55:23 +00:00
chess.griffin
bad9b196c4 upload HACKING to /doc directory; update SlackBuild to include this in packages 2009-03-25 13:08:26 +00:00
chess.griffin
0b69a3f72f fix LOGFILE to point to new LOGDIR not SBOPKGTMP 2009-03-24 18:23:47 +00:00
mauro.giachero
08e63b1f28 Refactor the renames code and fix upgrading renamed packages.
This patch refactors the renames code putting the old/new
name retrieval in two generic helpers.
Also fix the upgrading of renamed packages by providing
the old package name to upgradepkg.
Thanks to Phillip Warner for raising the issue, and to
Chess Griffin and slakmagik for testing and reviewing this
patch.

Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
2009-03-24 14:05:34 +00:00