mirror of
https://0xacab.org/sutty/sutty
synced 2024-11-16 11:41:41 +00:00
log de reindexación
This commit is contained in:
parent
0d6a2c020c
commit
b983353223
1 changed files with 19 additions and 2 deletions
|
@ -3,12 +3,29 @@
|
|||
# Reindexa los artículos al terminar la compilación
|
||||
class DeployReindex < Deploy
|
||||
def deploy
|
||||
time_start
|
||||
|
||||
site.reset
|
||||
site.indexed_posts.destroy_all
|
||||
site.index_posts!
|
||||
|
||||
Site.transaction do
|
||||
site.indexed_posts.destroy_all
|
||||
site.index_posts!
|
||||
end
|
||||
|
||||
time_stop
|
||||
|
||||
build_stats.create action: 'reindex',
|
||||
log: 'Reindex',
|
||||
seconds: time_spent_in_seconds,
|
||||
bytes: size,
|
||||
status: true
|
||||
site.touch
|
||||
end
|
||||
|
||||
def size
|
||||
0
|
||||
end
|
||||
|
||||
def limit
|
||||
1
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue