index.c

Checkout Tools
  • last updated a few seconds ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
revert recursive query logic. does not play nice with libdispatch

  1. … 7 more files in changeset.
add stdint

add a setting to configure region

  1. … 1 more file in changeset.
remove free call

clean up return cases

fix some formatting issues and check return status on a few things.

attempt to standardize the select count * code for indexes

  1. … 2 more files in changeset.
add some guards

fix a typo

wrap attach call in its own method

call finalize when we fail

  1. … 10 more files in changeset.
add list functionality to index. We can now list everything in the index via public api

  1. … 2 more files in changeset.
add a new public api for fetching indexes explicitly

  1. … 1 more file in changeset.
oops. remove debug statement

clean up error handler

  1. … 1 more file in changeset.
null last list entry

add debug friendly code and close the bzip file

  1. … 2 more files in changeset.
cast to intmax_t to shut up compiler warnings

Fix some warnings

  1. … 1 more file in changeset.
Use the new settings system to store the last time the index was fetched. This way we don't try over and over again if we haven't regeneratd server side.

  1. … 3 more files in changeset.
Add new mport_setting_get and mport_setting_set functions to allow users to customize settings. The sqlite3 master database now contains a settings table with name and val fields.

There are two obvious uses for this:

1. defining the country the user is in to pick the nearest mirror list.

2. storing the last time we fetched an index so it doesn't try to do it all the time when it's out of date and we haven't generated one on stargazer yet.

  1. … 24 more files in changeset.
The mport index should not be unloaded if a recentish version cannot be downloaded. If we have one to work with, use it. This allows mport list & friends to work when the index hasn't been updated on stargazer for some time or when network connectivity is limited. You can at least compare what you have installed to the last index.

Refactor the mirror list routine to return the number of mirrors. We may want this available later for display in a UI and it's helpful when debugging.

  1. … 2 more files in changeset.
add a new error state MPORT_ERR_WARN. This is a non fatal error that we could possibly work around.

Change the logic to loop through mirrors to make sense.

fallback to the bootstrap index url if the mirrors list fails.

  1. … 2 more files in changeset.
Clean up whitespace and comments.

Free memory when command fails to execute

  1. … 1 more file in changeset.
Add sha256 hash function wrappers. This allows us to verify a package file in the index was not tampered with and downloaded correctly.

  1. … 3 more files in changeset.
Add a new public index search function which will allow us to search index data via the search command I"m working on.

  1. … 1 more file in changeset.
Minor changs for mport.fetch

  1. … 2 more files in changeset.
fix attach routine

index is a reserved word so we can't attach the db as that.

Add license to index.

  1. … 1 more file in changeset.