123456789101112131415161718192021222324252627282930313233 |
- # Keep local history longer than 90 days
- --- a/chrome/browser/ungoogled_flag_entries.h
- +++ b/chrome/browser/ungoogled_flag_entries.h
- @@ -60,4 +60,8 @@
- "Popups to tabs",
- "Makes popups open in new tabs. ungoogled-chromium flag",
- kOsAll, SINGLE_VALUE_TYPE("popups-to-tabs")},
- + {"keep-old-history",
- + "Keep old history",
- + "Keep history older than 3 months. ungoogled-chromium flag",
- + kOsAll, SINGLE_VALUE_TYPE("keep-old-history")},
- #endif // CHROME_BROWSER_UNGOOGLED_FLAG_ENTRIES_H_
- --- a/components/history/core/browser/history_backend.cc
- +++ b/components/history/core/browser/history_backend.cc
- @@ -15,6 +15,7 @@
- #include <vector>
-
- #include "base/bind.h"
- +#include "base/command_line.h"
- #include "base/callback_helpers.h"
- #include "base/compiler_specific.h"
- #include "base/containers/flat_set.h"
- @@ -910,7 +911,8 @@ void HistoryBackend::InitImpl(
- db_->GetStartDate(&first_recorded_time_);
-
- // Start expiring old stuff.
- - expirer_.StartExpiringOldStuff(TimeDelta::FromDays(kExpireDaysThreshold));
- + if (!base::CommandLine::ForCurrentProcess()->HasSwitch("keep-old-history"))
- + expirer_.StartExpiringOldStuff(TimeDelta::FromDays(kExpireDaysThreshold));
-
- LOCAL_HISTOGRAM_TIMES("History.InitTime", TimeTicks::Now() - beginning_time);
- }
|