You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
conf_parser.add_argument("-f", "--conf-folder", dest='conf_folder', help="specify a folder for config files to live")
@@ -70,7 +87,8 @@ def fetch():
70
87
"chunk_size" : DEFAULT_CHUNK_SIZE,
71
88
"dest" : DEFAULT_DEST,
72
89
"task_count" : DEFAULT_TASK_COUNT,
73
-
"start_days" : DEFAULT_DAYS
90
+
"start_days" : DEFAULT_DAYS,
91
+
"end_days" : 0#today
74
92
}
75
93
76
94
try:
@@ -91,17 +109,16 @@ def fetch():
91
109
parser.add_argument("-n", "--num-parallel-fetches", dest="num_parallel_fetches", help="Number of fetches to make at once", type=int)
92
110
parser.add_argument("-cs", "--chunk-size", dest="chunk_size", help="Chunk size for writing from response to filesystem", type=int)
93
111
parser.add_argument("-u", "--singularity-uri-base", dest="singularity_uri_base", help="The base for singularity (eg. http://localhost:8080/singularity/v1)")
94
-
parser.add_argument("-s", "--start-days", dest="start_days", help="Search for logs no older than this many days", type=int)
95
-
parser.add_argument("-e", "--end-days", dest="end_days", help="Search for logs no new than this many days (defaults to None/today)", type=int)
112
+
parser.add_argument("-s", "--start-days", dest="start_days", help="Search for logs no older than this, can be an integer number of days or date in format 'mm-dd-yyyy'")
113
+
parser.add_argument("-e", "--end-days", dest="end_days", help="Search for logs no newer than this, can be an integer number of days or date in format 'mm-dd-yyyy' (defaults to None/today)")
96
114
parser.add_argument("-l", "--log-type", dest="logtype", help="Logfile type to downlaod (ie 'access.log'), can be a glob (ie *.log)")
97
115
parser.add_argument("-g", "--grep", dest="grep", help="Regex to grep for (normal grep syntax) or a full grep command")
98
116
99
117
args=parser.parse_args(remaining_argv)
100
118
101
-
ifargs.deployIdandnotargs.requestId:
102
-
exit("Must specify request-id (-r) when specifying deploy-id")
exit('Must specify one of\n -t task-id\n -r request-id and -d deploy-id\n -r request-id')
119
+
check_args(args)
120
+
args.start_days=convert_to_days(args.start_days)
121
+
args.end_days=convert_to_days(args.end_days)
105
122
106
123
args.dest=os.path.expanduser(args.dest)
107
124
@@ -121,7 +138,8 @@ def cat():
121
138
"chunk_size" : DEFAULT_CHUNK_SIZE,
122
139
"dest" : DEFAULT_DEST,
123
140
"task_count" : DEFAULT_TASK_COUNT,
124
-
"start_days" : DEFAULT_DAYS
141
+
"start_days" : DEFAULT_DAYS,
142
+
"end_days" : 0#today
125
143
}
126
144
127
145
try:
@@ -142,16 +160,15 @@ def cat():
142
160
parser.add_argument("-n", "--num-parallel-fetches", dest="num_parallel_fetches", help="Number of fetches to make at once", type=int)
143
161
parser.add_argument("-cs", "--chunk-size", dest="chunk_size", help="Chunk size for writing from response to filesystem", type=int)
144
162
parser.add_argument("-u", "--singularity-uri-base", dest="singularity_uri_base", help="The base for singularity (eg. http://localhost:8080/singularity/v1)")
145
-
parser.add_argument("-s", "--start-days", dest="start_days", help="Search for logs no older than this many days", type=int)
146
-
parser.add_argument("-e", "--end-days", dest="end_days", help="Search for logs no new than this many days (defaults to None/today)", type=int)
163
+
parser.add_argument("-s", "--start-days", dest="start_days", help="Search for logs no older than this, can be an integer number of days or date in format 'mm-dd-yyyy'")
164
+
parser.add_argument("-e", "--end-days", dest="end_days", help="Search for logs no newer than this, can be an integer number of days or date in format 'mm-dd-yyyy' (defaults to None/today)")
147
165
parser.add_argument("-l", "--logtype", dest="logtype", help="Logfile type to downlaod (ie 'access.log'), can be a glob (ie *.log)")
148
166
149
167
args=parser.parse_args(remaining_argv)
150
168
151
-
ifargs.deployIdandnotargs.requestId:
152
-
exit("Must specify requestId (-r) when specifying deploy-id")
0 commit comments