fix image search query to use placeholders.
[sgn.git] / bin / sequence_metadata / preprocess_featureprop_json.sh
blob4854bae9c2d271158fd89f0b01d2d0f383300a75
1 #! /usr/bin/env bash
3 # This shell script is called by the CXGN::Genotype::SequenceMetadata verify function and
4 # is used to preprocess the gff3 file for the featureprop_json table. It will:
5 # 1) remove comment lines from the file
6 # 2) sort the gff3 file by the seqid and start columns (1, 4)
8 # Usage: ./process_featurprop_json.sh <infile> <outfile>
10 if [ "$#" -ne 2 ]; then
11 echo "Usage: $0 <infile> <outfile>"
12 exit 1
15 grep -o '^[^#]*' "$1" | sort -t$'\t' -k1,1 -k4n,4 > "$2"