mirror of
https://github.com/sudoxnym/habitica-self-host.git
synced 2026-08-01 03:30:25 +00:00
feat(maintenance): post-downtime news & awards (#7406)
This commit is contained in:
parent
942ee522a1
commit
57754adee7
11 changed files with 510 additions and 407 deletions
10
common/dist/sprites/spritesmith-main-11.css
vendored
10
common/dist/sprites/spritesmith-main-11.css
vendored
|
|
@ -1960,31 +1960,31 @@
|
|||
width: 81px;
|
||||
height: 99px;
|
||||
}
|
||||
.Pet-LionCub-Base {
|
||||
.Pet-Lion-Veteran {
|
||||
background-image: url(spritesmith-main-11.png);
|
||||
background-position: -1640px -700px;
|
||||
width: 81px;
|
||||
height: 99px;
|
||||
}
|
||||
.Pet-LionCub-CottonCandyBlue {
|
||||
.Pet-LionCub-Base {
|
||||
background-image: url(spritesmith-main-11.png);
|
||||
background-position: -1640px -800px;
|
||||
width: 81px;
|
||||
height: 99px;
|
||||
}
|
||||
.Pet-LionCub-CottonCandyPink {
|
||||
.Pet-LionCub-CottonCandyBlue {
|
||||
background-image: url(spritesmith-main-11.png);
|
||||
background-position: -1640px -900px;
|
||||
width: 81px;
|
||||
height: 99px;
|
||||
}
|
||||
.Pet-LionCub-Desert {
|
||||
.Pet-LionCub-CottonCandyPink {
|
||||
background-image: url(spritesmith-main-11.png);
|
||||
background-position: -1640px -1000px;
|
||||
width: 81px;
|
||||
height: 99px;
|
||||
}
|
||||
.Pet-LionCub-Floral {
|
||||
.Pet-LionCub-Desert {
|
||||
background-image: url(spritesmith-main-11.png);
|
||||
background-position: -1640px -1100px;
|
||||
width: 81px;
|
||||
|
|
|
|||
BIN
common/dist/sprites/spritesmith-main-11.png
vendored
BIN
common/dist/sprites/spritesmith-main-11.png
vendored
Binary file not shown.
|
Before Width: | Height: | Size: 153 KiB After Width: | Height: | Size: 153 KiB |
780
common/dist/sprites/spritesmith-main-12.css
vendored
780
common/dist/sprites/spritesmith-main-12.css
vendored
File diff suppressed because it is too large
Load diff
BIN
common/dist/sprites/spritesmith-main-12.png
vendored
BIN
common/dist/sprites/spritesmith-main-12.png
vendored
Binary file not shown.
|
Before Width: | Height: | Size: 123 KiB After Width: | Height: | Size: 124 KiB |
BIN
common/img/sprites/spritesmith/stable/pets/Pet-Lion-Veteran.png
Normal file
BIN
common/img/sprites/spritesmith/stable/pets/Pet-Lion-Veteran.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 3.7 KiB |
|
|
@ -12,6 +12,7 @@
|
|||
"etherealLion": "Ethereal Lion",
|
||||
"veteranWolf": "Veteran Wolf",
|
||||
"veteranTiger": "Veteran Tiger",
|
||||
"veteranLion": "Veteran Lion",
|
||||
"cerberusPup": "Cerberus Pup",
|
||||
"hydra": "Hydra",
|
||||
"mantisShrimp": "Mantis Shrimp",
|
||||
|
|
|
|||
|
|
@ -426,6 +426,7 @@ api.specialPets = {
|
|||
'Phoenix-Base': 'phoenix',
|
||||
'Turkey-Gilded': 'gildedTurkey',
|
||||
'MagicalBee-Base': 'magicalBee',
|
||||
'Lion-Veteran': 'veteranLion',
|
||||
};
|
||||
|
||||
api.specialMounts = {
|
||||
|
|
|
|||
76
migrations/20160521_veteran_ladder.js
Normal file
76
migrations/20160521_veteran_ladder.js
Normal file
|
|
@ -0,0 +1,76 @@
|
|||
var migrationName = '20160521_veteran_ladder.js';
|
||||
var authorName = 'Sabe'; // in case script author needs to know when their ...
|
||||
var authorUuid = '7f14ed62-5408-4e1b-be83-ada62d504931'; //... own data is done
|
||||
|
||||
/*
|
||||
* Award Gilded Turkey pet to Turkey mount owners, Turkey Mount if they only have Turkey Pet,
|
||||
* and Turkey Pet otherwise
|
||||
*/
|
||||
|
||||
var dbserver = 'localhost:27017'; // FOR TEST DATABASE
|
||||
// var dbserver = 'username:password@ds031379-a0.mongolab.com:31379'; // FOR PRODUCTION DATABASE
|
||||
var dbname = 'habitrpg';
|
||||
|
||||
var mongo = require('mongoskin');
|
||||
var _ = require('lodash');
|
||||
|
||||
var dbUsers = mongo.db(dbserver + '/' + dbname + '?auto_reconnect').collection('users');
|
||||
|
||||
// specify a query to limit the affected users (empty for all users):
|
||||
var query = {
|
||||
'auth.timestamps.loggedin':{$gt:new Date('2016-05-01')} // remove when running migration a second time
|
||||
};
|
||||
|
||||
// specify fields we are interested in to limit retrieved data (empty if we're not reading data):
|
||||
var fields = {
|
||||
'migration': 1,
|
||||
'items.pets.Wolf-Veteran': 1,
|
||||
'items.pets.Tiger-Veteran': 1
|
||||
};
|
||||
|
||||
console.warn('Updating users...');
|
||||
var progressCount = 1000;
|
||||
var count = 0;
|
||||
dbUsers.findEach(query, fields, {batchSize:250}, function(err, user) {
|
||||
if (err) { return exiting(1, 'ERROR! ' + err); }
|
||||
if (!user) {
|
||||
console.warn('All appropriate users found and modified.');
|
||||
return displayData();
|
||||
}
|
||||
count++;
|
||||
|
||||
// specify user data to change:
|
||||
var set = {};
|
||||
if (user.migration !== migrationName) {
|
||||
if (user.items.pets['Tiger-Veteran']) {
|
||||
set = {'migration':migrationName, 'items.pets.Lion-Veteran':5};
|
||||
} else if (user.items.pets['Wolf-Veteran']) {
|
||||
set = {'migration':migrationName, 'items.pets.Tiger-Veteran':5};
|
||||
} else {
|
||||
set = {'migration':migrationName, 'items.pets.Wolf-Veteran':5};
|
||||
}
|
||||
}
|
||||
|
||||
dbUsers.update({_id:user._id}, {$set:set});
|
||||
|
||||
if (count%progressCount == 0) console.warn(count + ' ' + user._id);
|
||||
if (user._id == authorUuid) console.warn(authorName + ' processed');
|
||||
});
|
||||
|
||||
|
||||
function displayData() {
|
||||
console.warn('\n' + count + ' users processed\n');
|
||||
return exiting(0);
|
||||
}
|
||||
|
||||
|
||||
function exiting(code, msg) {
|
||||
code = code || 0; // 0 = success
|
||||
if (code && !msg) { msg = 'ERROR!'; }
|
||||
if (msg) {
|
||||
if (code) { console.error(msg); }
|
||||
else { console.log( msg); }
|
||||
}
|
||||
process.exit(code);
|
||||
}
|
||||
|
||||
|
|
@ -30,7 +30,7 @@ api.getFrontPage = {
|
|||
let staticPages = ['front', 'privacy', 'terms', 'api-v2', 'features',
|
||||
'videos', 'contact', 'plans', 'new-stuff', 'community-guidelines',
|
||||
'old-news', 'press-kit', 'faq', 'overview', 'apps',
|
||||
'clear-browser-data', 'merch'];
|
||||
'clear-browser-data', 'merch', 'maintenance-info'];
|
||||
|
||||
_.each(staticPages, (name) => {
|
||||
api[`get${name}Page`] = {
|
||||
|
|
|
|||
|
|
@ -48,6 +48,7 @@ export let schema = new Schema({
|
|||
// We want to know *every* time an object updates. Mongoose uses __v to designate when an object contains arrays which
|
||||
// have been updated (http://goo.gl/gQLz41), but we want *every* update
|
||||
_v: { type: Number, default: 0 },
|
||||
migration: String,
|
||||
achievements: {
|
||||
originalUser: Boolean,
|
||||
habitSurveys: Number,
|
||||
|
|
|
|||
|
|
@ -1,26 +1,44 @@
|
|||
h2 5/19/2016 - IMPORTANT: UPCOMING MAINTENANCE!
|
||||
h2 5/21/2016 - WELCOME BACK, HABITICA!
|
||||
hr
|
||||
tr
|
||||
td
|
||||
h3 Maintenance to Take Place May 21
|
||||
p This Saturday, we will be performing important maintenance on Habitica to build out the groundwork for some exciting upcoming features! We'll be doing everything we can to make this as smooth as possible, but unfortunately, there will be significant downtime for much of the day.
|
||||
br
|
||||
p.strong We expect that on Saturday, May 21st, Habitica will be unavailable between <a href='http://www.worldtimebuddy.com/?pl=1&lid=5368361,100&h=5368361' target='_blank'>1 PM and 10 PM Pacific Time (8 pm - 5 am UTC)</a>.
|
||||
ul
|
||||
li Don't worry, <strong>you will NOT lose any streaks or take any damage during this weekend, not even from Bosses!</strong> This maintenance will not harm your accounts.
|
||||
li If you will need to see your task list on Saturday, <strong>we recommend taking a screenshot of your tasks before the maintenance begins</strong> so that you can use them as a reference during downtime.
|
||||
li At the end of the maintenance, to thank people for their patience, <strong>everyone will receive a rare Veteran pet!</strong>
|
||||
li This maintenance should not result in any major visible differences to the site; it's all behind-the-scenes work. However, <strong>at the end of it, we will release new updates to the mobile apps, which will be required in order for the apps to work properly with the new changes!</strong> Be sure to download those updates on Saturday as soon as they are released.
|
||||
li For more information, please <strong>check out our detailed <a href='/static/maintenance-info'>info page</a> about the maintenance!</strong> And if you have any further questions or concerns, feel free to reach out to Leslie (<a href='mailto:leslie@habitica.com' target='_blank'>leslie@habitica.com</a>), and she will be happy to help you.
|
||||
p We understand that it's very frustrating to have Habitica unavailable for such a long part of the day. Rest assured that we'll be doing everything we can to make the maintenance go as quickly as possible, but with over a million Habitican accounts to migrate, this is a hefty task! During the maintenance on Saturday we will be posting regular status reports on our <a href='https://twitter.com/habitica' target='_blank'>Twitter account</a>, so you can follow us for the most accurate updates.
|
||||
br
|
||||
p Thank you for your patience, and for using Habitica!
|
||||
h3 Welcome Back, Everyone!
|
||||
p Hurrah! After many hours of toil, our valiant blacksmiths were able to complete our <a href='/static/maintenance-info' target='_blank'>planned maintenance</a> ahead of schedule. The site should be working normally again! If you notice any issues or have any questions, please feel free to email us at <a href='mailto:admin@habitica.com' target='_blank'>admin@habitica.com</a> and we will be happy to help.
|
||||
tr
|
||||
td
|
||||
h3 Important Mobile App Updates
|
||||
p We’ve released an <a href='https://geo.itunes.apple.com/us/app/habitica/id994882113?mt=8' target='_blank'>iOS update</a> and an <a href='https://play.google.com/store/apps/details?id=com.habitrpg.android.habitica' target='_blank'>Android update</a> that contain the new code. It’s very important to download these updates immediately, or you may encounter significant bugs!
|
||||
tr
|
||||
td
|
||||
.Pet-Wolf-Veteran.pull-right
|
||||
h3 Veteran Pets
|
||||
p To thank you for your patience during the maintenance, we have awarded everyone a special Veteran Pet! You can see it under <a href='/#/options/inventory/pets'>Inventory > Pets</a>, at the bottom of the screen. If it hasn’t appeared yet, never fear: because there are so many Habiticans, it can sometimes take an hour or two for everyone to receive their pet. You will have it soon! Thanks again for bearing with us during the downtime.
|
||||
tr
|
||||
td
|
||||
h3 Daily Safe Mode
|
||||
p To protect the accounts of Habiticans in different time zones across the world, we enabled Cron Daily Safe Mode during the maintenance, which will prevent you from taking any damage or losing any streaks for the rest of the weekend. Let us know at <a href='mailto:admin@habitica.com' target='_blank'>admin@habitica.com</a> if you have any questions or concerns!
|
||||
|
||||
if menuItem !== 'oldNews'
|
||||
hr
|
||||
a(href='/static/old-news', target='_blank') Read older news
|
||||
|
||||
mixin oldNews
|
||||
h2 5/19/2016 - IMPORTANT: UPCOMING MAINTENANCE!
|
||||
tr
|
||||
td
|
||||
h3 Maintenance to Take Place May 21
|
||||
p This Saturday, we will be performing important maintenance on Habitica to build out the groundwork for some exciting upcoming features! We'll be doing everything we can to make this as smooth as possible, but unfortunately, there will be significant downtime for much of the day.
|
||||
br
|
||||
p.strong We expect that on Saturday, May 21st, Habitica will be unavailable between <a href='http://www.worldtimebuddy.com/?pl=1&lid=5368361,100&h=5368361' target='_blank'>1 PM and 10 PM Pacific Time (8 pm - 5 am UTC)</a>.
|
||||
ul
|
||||
li Don't worry, <strong>you will NOT lose any streaks or take any damage during this weekend, not even from Bosses!</strong> This maintenance will not harm your accounts.
|
||||
li If you will need to see your task list on Saturday, <strong>we recommend taking a screenshot of your tasks before the maintenance begins</strong> so that you can use them as a reference during downtime.
|
||||
li At the end of the maintenance, to thank people for their patience, <strong>everyone will receive a rare Veteran pet!</strong>
|
||||
li This maintenance should not result in any major visible differences to the site; it's all behind-the-scenes work. However, <strong>at the end of it, we will release new updates to the mobile apps, which will be required in order for the apps to work properly with the new changes!</strong> Be sure to download those updates on Saturday as soon as they are released.
|
||||
li For more information, please <strong>check out our detailed <a href='/static/maintenance-info'>info page</a> about the maintenance!</strong> And if you have any further questions or concerns, feel free to reach out to Leslie (<a href='mailto:leslie@habitica.com' target='_blank'>leslie@habitica.com</a>), and she will be happy to help you.
|
||||
p We understand that it's very frustrating to have Habitica unavailable for such a long part of the day. Rest assured that we'll be doing everything we can to make the maintenance go as quickly as possible, but with over a million Habitican accounts to migrate, this is a hefty task! During the maintenance on Saturday we will be posting regular status reports on our <a href='https://twitter.com/habitica' target='_blank'>Twitter account</a>, so you can follow us for the most accurate updates.
|
||||
br
|
||||
p Thank you for your patience, and for using Habitica!
|
||||
h2 5/17/2016 - TREELING PET QUEST AND CHALLENGE SPOTLIGHT!
|
||||
tr
|
||||
td
|
||||
|
|
|
|||
Loading…
Reference in a new issue