Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
crawlersNoticias
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
4
Issues
4
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
m3
crawlersNoticias
Commits
c8ff1f67
Commit
c8ff1f67
authored
2 years ago
by
Mario Chirinos
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
last date finder
parent
3101d32e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
2 deletions
+1
-2
siteCrawler.py
scripts/siteCrawler.py
+1
-2
No files found.
scripts/siteCrawler.py
View file @
c8ff1f67
...
...
@@ -45,7 +45,7 @@ def crawlNews(directory, cfg, endDate=datetime.datetime.now()):
startDate
=
datetime
.
datetime
.
strptime
(
cfg
[
"startDate"
],
'
%
Y-
%
m-
%
d'
)
delta
=
endDate
-
startDate
return
0
for
i
in
range
(
delta
.
days
+
1
):
day
=
startDate
+
datetime
.
timedelta
(
days
=
i
)
yeardir
=
directory
+
str
(
day
.
year
)
+
"/"
...
...
@@ -68,7 +68,6 @@ def main(argv):
with
open
(
argv
[
1
]
+
'settings.json'
)
as
json_file
:
cfg
=
json
.
load
(
json_file
)
print
(
cfg
)
return
0
if
len
(
argv
)
==
2
:
crawlNews
(
argv
[
1
],
cfg
)
if
len
(
argv
)
==
3
:
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment