-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Open
Description
I've noticed that ag yields a false positive.
Reproduction Guide
# Grab yourself a copy of linux (I was working on the given commit)
mkdir linux && cd linux && git init
git remote add origin https://github.com/torvalds/linux.git
git fetch --depth 1 origin 89f5e14d05b4852db5ecdf222dc6a13edc633658
git checkout FETCH_HEAD
# Run ag searching for a certain fadvise.sh
ag -l -u -Q foo . | grep fadvise.shYou will notice that this spits out
tools/perf/trace/beauty/fadvise.sh
Searching with grep, however, shows that there is no mention of foo within fadvise.sh.
grep foo tools/perf/trace/beauty/fadvise.shyields nothing.
System Details
ag --version
ag version 2.2.0
Features:
+jit +lzma +zlibuname -a
Linux fedora 6.10.10-200.fc40.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Sep 12 18:26:09 UTC 2024 x86_64 GNU/Linux
cat /etc/os-release
NAME="Fedora Linux"
VERSION="40 (Workstation Edition)"
ID=fedora
VERSION_ID=40
VERSION_CODENAME=""
PLATFORM_ID="platform:f40"
PRETTY_NAME="Fedora Linux 40 (Workstation Edition)"
ANSI_COLOR="0;38;2;60;110;180"
LOGO=fedora-logo-icon
CPE_NAME="cpe:/o:fedoraproject:fedora:40"
DEFAULT_HOSTNAME="fedora"
HOME_URL="https://fedoraproject.org/"
DOCUMENTATION_URL="https://docs.fedoraproject.org/en-US/fedora/f40/system-administrators-guide/"
SUPPORT_URL="https://ask.fedoraproject.org/"
BUG_REPORT_URL="https://bugzilla.redhat.com/"
REDHAT_BUGZILLA_PRODUCT="Fedora"
REDHAT_BUGZILLA_PRODUCT_VERSION=40
REDHAT_SUPPORT_PRODUCT="Fedora"
REDHAT_SUPPORT_PRODUCT_VERSION=40
SUPPORT_END=2025-05-13
VARIANT="Workstation Edition"
VARIANT_ID=workstation
dnf info the_silver_searcher
Name : the_silver_searcher
Version : 2.2.0^2020704.5a1c8d8
Release : 8.fc40
Architecture : x86_64
Size : 122 k
Source : the_silver_searcher-2.2.0^2020704.5a1c8d8-8.fc40.src.rpm
Repository : @System
From repo : fedora
Summary : Super-fast text searching tool (ag)
URL : https://github.com/ggreer/the_silver_searcher
License : ASL 2.0 and BSD
Description : The Silver Searcher is a code searching tool similar to ack,
: with a focus on speed.
Current Progress
I have not performed any investigation where this unexpected result may be coming from.
Metadata
Metadata
Assignees
Labels
No labels