Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 60 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: CI

on:
# Triggers the workflow on push or pull request events but only for the "master" branch
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v4
- uses: shogo82148/actions-setup-perl@v1
with:
perl-version: "5.38"

- name: Install
run: |
sudo apt-get install -y zip gzip git curl libdb-dev
cpanm --quiet --notest JSON Path::Tiny LWP::Simple Bio::Perl
wget http://ftp.ncbi.nlm.nih.gov/blast/executables/blast+/2.16.0/ncbi-blast-2.16.0+-x64-linux.tar.gz
tar zxvf ncbi-blast-2.16.0+-x64-linux.tar.gz
curl https://raw.githubusercontent.com/tseemann/any2fasta/master/any2fasta > bin/any2fasta
chmod +x bin/any2fasta
export PATH=$PWD/bin:$PWD/ncbi-blast-2.16.0+/bin:$PATH

- name: Test
run: |
export PATH=$PWD/bin:$PWD/ncbi-blast-2.16.0+/bin:$PATH
abricate --setupdb
abricate --version
abricate --help
abricate --check
abricate --list
! abricate --doesnotexist || echo "fail expected"
! abricate --threads 0
! (abricate test/assembly.fa | grep '~~~')
abricate test/assembly.fa > 1.tab
abricate test/assembly.fa.gz > 2.tab
abricate test/assembly.gbk > 3.tab
abricate test/assembly.gbk.gz > 4.tab
abricate --nopath test/assembly.gbk.gz | grep '^assembly.gbk.gz'
abricate --summary {1,2,3,4}.tab > summary.tab
abricate --summary 1.tab 2.tab 1.tab |& grep 'duplicate'
abricate --summary <(cat 1.tab 2.tab 3.tab) | wc -l | grep -w 4
abricate test/assembly.txt |& grep ERROR
abricate not_exist.embl |& grep ERROR
abricate --threads `nproc` test/assembly.fa.bz2 | grep -i FOSFOMYCIN
abricate --threads `nproc` test/assembly.fa.bz2 | grep -i lactam
for DB in `abricate --list | cut -f1 | tail -n +2`; do abricate --db $DB test/assembly.fa > /dev/null ; done
abricate-get_db --help
abricate-get_db --db ncbi --dbdir .
! grep 'FUSIDIC ACID' ncbi/sequences
abricate --threads `nproc` --fofn test/fofn.txt
32 changes: 17 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
[![Build Status](https://travis-ci.org/tseemann/abricate.svg?branch=master)](https://travis-ci.org/tseemann/abricate)
[![License: GPL v2](https://img.shields.io/badge/License-GPL%20v2-blue.svg)](https://www.gnu.org/licenses/old-licenses/gpl-2.0.en.html)
![Don't judge me](https://img.shields.io/badge/Language-Perl_5-steelblue.svg)

Expand Down Expand Up @@ -157,16 +156,19 @@ columns:
```
% abricate --list

DATABASE SEQUENCES DBTYPE DATE
argannot 1749 nucl 2019-Jul-28
card 2241 nucl 2019-Jul-28
ecoh 597 nucl 2019-Jul-28
ecoli_vf 2701 nucl 2019-Jul-28
megares 6635 nucl 2020-Feb-20
ncbi 4324 nucl 2019-Jul-28
plasmidfinder 263 nucl 2019-Jul-28
resfinder 2434 nucl 2019-Jul-28
vfdb 2597 nucl 2019-Jul-28
DATABASE SEQUENCES DBTYPE DATE
ecoh 597 nucl 2025-Apr-14
bacmet2 746 nucl 2025-Apr-14
ncbi 7456 nucl 2025-Apr-14
victors 4545 nucl 2025-Apr-14
vfdb 4394 nucl 2025-Apr-14
megares 7424 nucl 2025-Apr-14
card 6048 nucl 2025-Apr-14
plasmidfinder 488 nucl 2025-Apr-14
resfinder 3174 nucl 2025-Apr-14
argannot 2224 nucl 2025-Apr-14
ecoli_vf 2701 nucl 2025-Apr-14

```

The default database is `ncbi`.
Expand Down Expand Up @@ -256,14 +258,14 @@ If you publish the results of Abricate please cite both the software _and_
the appropriate database you used with `--db`

* Seemann T, *Abricate*, **Github** `https://github.com/tseemann/abricate`
* NCBI AMRFinderPlus - [doi: 10.1128/AAC.00483-19](https://www.ncbi.nlm.nih.gov/pmc/articles/PMC6811410)
* CARD - [doi:10.1093/nar/gkw1004](https://www.ncbi.nlm.nih.gov/pubmed/27789705)
* Resfinder - [doi:10.1093/jac/dks261](https://www.ncbi.nlm.nih.gov/pubmed/22782487)
* NCBI AMRFinderPlus - [doi:10.1038/s41598-021-91456-0](https://pubmed.ncbi.nlm.nih.gov/34135355/)
* CARD - [doi:10.1093/nar/gkac920](https://pubmed.ncbi.nlm.nih.gov/36263822/)
* Resfinder - [doi:10.1093/jac/dkaa345](https://pubmed.ncbi.nlm.nih.gov/32780112/)
* ARG-ANNOT - [doi:10.1128/AAC.01310-13](https://www.ncbi.nlm.nih.gov/pubmed/24145532)
* VFDB - [doi:10.1093/nar/gkv1239](https://www.ncbi.nlm.nih.gov/pubmed/26578559)
* PlasmidFinder - [doi:10.1128/AAC.02412-14](https://www.ncbi.nlm.nih.gov/pubmed/24777092)
* EcOH - [doi:10.1099/mgen.0.000064](https://www.ncbi.nlm.nih.gov/pmc/articles/PMC5343136/)
* MEGARES 2.00 - [doi:10.1093/nar/gkz1010](https://academic.oup.com/nar/article/48/D1/D561/5624973)
* MEGARES 3.00 - [doi:10.1093/nar/gkac1047](https://pubmed.ncbi.nlm.nih.gov/36382407/)
## Issues

Please report problems to the [Issues Page](https://github.com/tseemann/abricate/issues).
Expand Down
10 changes: 5 additions & 5 deletions bin/abricate-get_db
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ sub get_tag {
sub get_ncbi {
my $AFP = "https://ftp.ncbi.nlm.nih.gov/pathogen/Antimicrobial_resistance/AMRFinderPlus/database/latest";
#my $src = "https://ftp.ncbi.nlm.nih.gov/pathogen/Antimicrobial_resistance/AMRFinderPlus/data/latest/AMR_CDS";
my $src = "$AFP/AMR_CDS";
my $src = "$AFP/AMR_CDS.fa";
my $name = "amr_cds.ffn";
#my $src2 = "https://ftp.ncbi.nlm.nih.gov/pathogen/Antimicrobial_resistance/AMRFinderPlus/data/latest/ReferenceGeneCatalog.txt";
my $src2 = "$AFP/ReferenceGeneCatalog.txt";
Expand Down Expand Up @@ -347,7 +347,7 @@ sub get_plasmidfinder {
#..............................................................................
sub get_megares {
my $zip = "megares.zip";
download('https://megares.meglab.org/download/megares_v2.00.zip', $zip);
download('https://www.meglab.org/downloads/megares_v3.00.zip', $zip);
system("unzip -j -u $zip");
my $seqs = load_fasta( glob("megares_drugs_*.fasta") );
my @okseq;
Expand Down Expand Up @@ -380,7 +380,7 @@ sub get_argannot {
download(
# 'http://www.mediterranee-infection.com/arkotheque/client/ihumed/_depot_arko/articles/1425/argannot-aa-v3-march2017_doc.fasta',
# 'http://www.mediterranee-infection.com/arkotheque/client/ihumed/_depot_arko/articles/691/argannot-nt_doc.fasta',
'https://www.mediterranee-infection.com/wp-content/uploads/2019/06/ARG_ANNOT_V5_Nt_JUNE2019.txt',
'https://www.mediterranee-infection.com/wp-content/uploads/2019/09/ARG-ANNOT_NT_V6_July2019.txt',
$fasta
);

Expand Down Expand Up @@ -501,10 +501,10 @@ sub get_victors {
# the PROT data is in .faa and has the protein ref and /product

#>gi|115534241:2616-3152 Campylobacter jejuni plasmid pCJ01, complete sequence
download('http://www.phidias.us/victors/downloads/gen_downloads.php', 'victors.ffn');
download('http://phidias.us/victors/downloads/gen_downloads.php', 'victors.ffn');

#>gi|115534244|ref|YP_783826.1| hypothetical protein pCJ01p4 [Campylobacter jejuni]
download('http://www.phidias.us/victors/downloads/gen_downloads_protein.php', 'victors.faa');
download('http://phidias.us/victors/downloads/gen_downloads_protein.php', 'victors.faa');

my %gi;
open my $FAA, '<', 'victors.faa';
Expand Down
Loading