From 90f8fe7e538bb7e52d2558152a0390e693f39b11 Mon Sep 17 00:00:00 2001 From: Akihiko Odaki Date: Thu, 29 Mar 2018 01:20:40 +0900 Subject: [PATCH] Introduce processor --- gulpfile.ts | 28 ++++++------- package.json | 2 + src/{common => }/build/fa.ts | 0 src/{common => }/build/i18n.ts | 2 +- src/{common => }/build/license.ts | 2 +- src/index.ts | 38 +++++++++++++----- src/parse-opt.ts | 17 ++++++++ src/processor/index.ts | 4 ++ src/processor/report-github-failure.ts | 29 +++++++++++++ src/queue.ts | 10 +++++ src/{ => server}/api/api-handler.ts | 0 src/{ => server}/api/authenticate.ts | 0 src/{ => server}/api/bot/core.ts | 0 src/{ => server}/api/bot/interfaces/line.ts | 4 +- src/{ => server}/api/common/drive/add-file.ts | 2 +- .../api/common/drive/upload_from_url.ts | 0 .../api/common/generate-native-user-token.ts | 0 src/{ => server}/api/common/get-friends.ts | 0 src/{ => server}/api/common/get-host-lower.ts | 0 .../api/common/is-native-token.ts | 0 src/{ => server}/api/common/notify.ts | 0 src/{ => server}/api/common/push-sw.ts | 2 +- .../api/common/read-messaging-message.ts | 0 .../api/common/read-notification.ts | 0 src/{ => server}/api/common/signin.ts | 2 +- .../common/text/core/syntax-highlighter.ts | 0 .../api/common/text/elements/bold.ts | 0 .../api/common/text/elements/code.ts | 0 .../api/common/text/elements/emoji.ts | 0 .../api/common/text/elements/hashtag.ts | 0 .../api/common/text/elements/inline-code.ts | 0 .../api/common/text/elements/link.ts | 0 .../api/common/text/elements/mention.ts | 0 .../api/common/text/elements/quote.ts | 0 .../api/common/text/elements/url.ts | 0 src/{ => server}/api/common/text/index.ts | 0 src/{ => server}/api/common/watch-post.ts | 0 src/{ => server}/api/endpoints.ts | 0 .../api/endpoints/aggregation/posts.ts | 0 .../endpoints/aggregation/posts/reaction.ts | 0 .../endpoints/aggregation/posts/reactions.ts | 0 .../api/endpoints/aggregation/posts/reply.ts | 0 .../api/endpoints/aggregation/posts/repost.ts | 0 .../api/endpoints/aggregation/users.ts | 0 .../endpoints/aggregation/users/activity.ts | 0 .../endpoints/aggregation/users/followers.ts | 0 .../endpoints/aggregation/users/following.ts | 0 .../api/endpoints/aggregation/users/post.ts | 0 .../endpoints/aggregation/users/reaction.ts | 0 src/{ => server}/api/endpoints/app/create.ts | 0 .../api/endpoints/app/name_id/available.ts | 0 src/{ => server}/api/endpoints/app/show.ts | 0 src/{ => server}/api/endpoints/auth/accept.ts | 0 .../api/endpoints/auth/session/generate.ts | 2 +- .../api/endpoints/auth/session/show.ts | 0 .../api/endpoints/auth/session/userkey.ts | 0 src/{ => server}/api/endpoints/channels.ts | 0 .../api/endpoints/channels/create.ts | 0 .../api/endpoints/channels/posts.ts | 0 .../api/endpoints/channels/show.ts | 0 .../api/endpoints/channels/unwatch.ts | 0 .../api/endpoints/channels/watch.ts | 0 src/{ => server}/api/endpoints/drive.ts | 0 src/{ => server}/api/endpoints/drive/files.ts | 0 .../api/endpoints/drive/files/create.ts | 0 .../api/endpoints/drive/files/find.ts | 0 .../api/endpoints/drive/files/show.ts | 0 .../api/endpoints/drive/files/update.ts | 0 .../endpoints/drive/files/upload_from_url.ts | 0 .../api/endpoints/drive/folders.ts | 0 .../api/endpoints/drive/folders/create.ts | 0 .../api/endpoints/drive/folders/find.ts | 0 .../api/endpoints/drive/folders/show.ts | 0 .../api/endpoints/drive/folders/update.ts | 0 .../api/endpoints/drive/stream.ts | 0 .../api/endpoints/following/create.ts | 0 .../api/endpoints/following/delete.ts | 0 src/{ => server}/api/endpoints/i.ts | 0 src/{ => server}/api/endpoints/i/2fa/done.ts | 0 .../api/endpoints/i/2fa/register.ts | 2 +- .../api/endpoints/i/2fa/unregister.ts | 0 .../api/endpoints/i/appdata/get.ts | 0 .../api/endpoints/i/appdata/set.ts | 0 .../api/endpoints/i/authorized_apps.ts | 0 .../api/endpoints/i/change_password.ts | 0 src/{ => server}/api/endpoints/i/favorites.ts | 0 .../api/endpoints/i/notifications.ts | 0 src/{ => server}/api/endpoints/i/pin.ts | 0 .../api/endpoints/i/regenerate_token.ts | 0 .../api/endpoints/i/signin_history.ts | 0 src/{ => server}/api/endpoints/i/update.ts | 2 +- .../api/endpoints/i/update_client_setting.ts | 0 .../api/endpoints/i/update_home.ts | 0 .../api/endpoints/i/update_mobile_home.ts | 0 .../api/endpoints/messaging/history.ts | 0 .../api/endpoints/messaging/messages.ts | 0 .../endpoints/messaging/messages/create.ts | 2 +- .../api/endpoints/messaging/unread.ts | 0 src/{ => server}/api/endpoints/meta.ts | 4 +- src/{ => server}/api/endpoints/mute/create.ts | 0 src/{ => server}/api/endpoints/mute/delete.ts | 0 src/{ => server}/api/endpoints/mute/list.ts | 0 src/{ => server}/api/endpoints/my/apps.ts | 0 .../notifications/get_unread_count.ts | 0 .../notifications/mark_as_read_all.ts | 0 .../api/endpoints/othello/games.ts | 0 .../api/endpoints/othello/games/show.ts | 0 .../api/endpoints/othello/invitations.ts | 0 .../api/endpoints/othello/match.ts | 0 .../api/endpoints/othello/match/cancel.ts | 0 src/{ => server}/api/endpoints/posts.ts | 0 .../api/endpoints/posts/categorize.ts | 0 .../api/endpoints/posts/context.ts | 0 .../api/endpoints/posts/create.ts | 2 +- .../api/endpoints/posts/favorites/create.ts | 0 .../api/endpoints/posts/favorites/delete.ts | 0 .../api/endpoints/posts/mentions.ts | 0 .../endpoints/posts/polls/recommendation.ts | 0 .../api/endpoints/posts/polls/vote.ts | 0 .../api/endpoints/posts/reactions.ts | 0 .../api/endpoints/posts/reactions/create.ts | 0 .../api/endpoints/posts/reactions/delete.ts | 0 .../api/endpoints/posts/replies.ts | 0 .../api/endpoints/posts/reposts.ts | 0 .../api/endpoints/posts/search.ts | 0 src/{ => server}/api/endpoints/posts/show.ts | 0 .../api/endpoints/posts/timeline.ts | 0 src/{ => server}/api/endpoints/posts/trend.ts | 0 src/{ => server}/api/endpoints/stats.ts | 0 src/{ => server}/api/endpoints/sw/register.ts | 0 .../api/endpoints/username/available.ts | 0 src/{ => server}/api/endpoints/users.ts | 0 .../api/endpoints/users/followers.ts | 0 .../api/endpoints/users/following.ts | 0 .../users/get_frequently_replied_users.ts | 0 src/{ => server}/api/endpoints/users/posts.ts | 0 .../api/endpoints/users/recommendation.ts | 0 .../api/endpoints/users/search.ts | 2 +- .../api/endpoints/users/search_by_username.ts | 0 src/{ => server}/api/endpoints/users/show.ts | 0 src/{ => server}/api/event.ts | 2 +- src/{ => server}/api/limitter.ts | 2 +- src/{ => server}/api/models/access-token.ts | 2 +- src/{ => server}/api/models/app.ts | 4 +- src/{ => server}/api/models/appdata.ts | 2 +- src/{ => server}/api/models/auth-session.ts | 2 +- .../api/models/channel-watching.ts | 2 +- src/{ => server}/api/models/channel.ts | 2 +- src/{ => server}/api/models/drive-file.ts | 4 +- src/{ => server}/api/models/drive-folder.ts | 2 +- src/{ => server}/api/models/drive-tag.ts | 2 +- src/{ => server}/api/models/favorite.ts | 2 +- src/{ => server}/api/models/following.ts | 2 +- .../api/models/messaging-history.ts | 2 +- .../api/models/messaging-message.ts | 2 +- src/{ => server}/api/models/meta.ts | 2 +- src/{ => server}/api/models/mute.ts | 2 +- src/{ => server}/api/models/notification.ts | 2 +- src/{ => server}/api/models/othello-game.ts | 2 +- .../api/models/othello-matching.ts | 2 +- src/{ => server}/api/models/poll-vote.ts | 2 +- src/{ => server}/api/models/post-reaction.ts | 2 +- src/{ => server}/api/models/post-watching.ts | 2 +- src/{ => server}/api/models/post.ts | 2 +- src/{ => server}/api/models/signin.ts | 2 +- .../api/models/sw-subscription.ts | 2 +- src/{ => server}/api/models/user.ts | 4 +- src/{ => server}/api/private/signin.ts | 2 +- src/{ => server}/api/private/signup.ts | 4 +- src/{ => server}/api/reply.ts | 0 src/{ => server}/api/server.ts | 0 src/{ => server}/api/service/github.ts | 38 ++++++------------ src/{ => server}/api/service/twitter.ts | 4 +- src/{ => server}/api/stream/channel.ts | 0 src/{ => server}/api/stream/drive.ts | 0 src/{ => server}/api/stream/home.ts | 0 .../api/stream/messaging-index.ts | 0 src/{ => server}/api/stream/messaging.ts | 0 src/{ => server}/api/stream/othello-game.ts | 0 src/{ => server}/api/stream/othello.ts | 0 src/{ => server}/api/stream/requests.ts | 0 src/{ => server}/api/stream/server.ts | 0 src/{ => server}/api/streaming.ts | 2 +- .../common/get-notification-summary.ts | 0 src/{ => server}/common/get-post-summary.ts | 0 src/{ => server}/common/get-reaction-emoji.ts | 0 src/{ => server}/common/othello/ai/back.ts | 2 +- src/{ => server}/common/othello/ai/front.ts | 2 +- src/{ => server}/common/othello/ai/index.ts | 0 src/{ => server}/common/othello/core.ts | 0 src/{ => server}/common/othello/maps.ts | 0 src/{ => server}/common/user/get-acct.ts | 0 src/{ => server}/common/user/get-summary.ts | 0 src/{ => server}/common/user/parse-acct.ts | 0 src/{ => server}/file/assets/avatar.jpg | Bin src/{ => server}/file/assets/bad-egg.png | Bin src/{ => server}/file/assets/dummy.png | Bin src/{ => server}/file/assets/not-an-image.png | Bin .../file/assets/thumbnail-not-available.png | Bin src/{ => server}/file/server.ts | 0 src/{server.ts => server/index.ts} | 38 +++++++----------- src/{ => server}/log-request.ts | 0 src/{ => server}/web/app/animation.styl | 0 src/{ => server}/web/app/app.styl | 0 src/{ => server}/web/app/app.vue | 0 src/{ => server}/web/app/auth/assets/logo.svg | 0 src/{ => server}/web/app/auth/script.ts | 0 src/{ => server}/web/app/auth/style.styl | 0 src/{ => server}/web/app/auth/views/form.vue | 0 src/{ => server}/web/app/auth/views/index.vue | 0 src/{ => server}/web/app/base.pug | 6 +-- src/{ => server}/web/app/boot.js | 0 src/{ => server}/web/app/ch/script.ts | 0 src/{ => server}/web/app/ch/style.styl | 0 src/{ => server}/web/app/ch/tags/channel.tag | 0 src/{ => server}/web/app/ch/tags/header.tag | 0 src/{ => server}/web/app/ch/tags/index.tag | 0 src/{ => server}/web/app/ch/tags/index.ts | 0 .../web/app/common/define-widget.ts | 0 src/{ => server}/web/app/common/mios.ts | 0 .../app/common/scripts/check-for-update.ts | 0 .../common/scripts/compose-notification.ts | 0 .../web/app/common/scripts/contains.ts | 0 .../app/common/scripts/copy-to-clipboard.ts | 0 .../web/app/common/scripts/date-stringify.ts | 0 .../web/app/common/scripts/fuck-ad-block.ts | 0 .../web/app/common/scripts/gcd.ts | 0 .../web/app/common/scripts/get-kao.ts | 0 .../web/app/common/scripts/get-median.ts | 0 .../web/app/common/scripts/loading.ts | 0 .../app/common/scripts/parse-search-query.ts | 0 .../app/common/scripts/streaming/channel.ts | 0 .../web/app/common/scripts/streaming/drive.ts | 0 .../web/app/common/scripts/streaming/home.ts | 0 .../scripts/streaming/messaging-index.ts | 0 .../app/common/scripts/streaming/messaging.ts | 0 .../common/scripts/streaming/othello-game.ts | 0 .../app/common/scripts/streaming/othello.ts | 0 .../app/common/scripts/streaming/requests.ts | 0 .../app/common/scripts/streaming/server.ts | 0 .../scripts/streaming/stream-manager.ts | 0 .../app/common/scripts/streaming/stream.ts | 0 .../common/views/components/autocomplete.vue | 0 .../connect-failed.troubleshooter.vue | 0 .../views/components/connect-failed.vue | 0 .../app/common/views/components/ellipsis.vue | 0 .../views/components/file-type-icon.vue | 0 .../app/common/views/components/forkit.vue | 0 .../web/app/common/views/components/index.ts | 0 .../common/views/components/media-list.vue | 0 .../views/components/messaging-room.form.vue | 0 .../components/messaging-room.message.vue | 0 .../views/components/messaging-room.vue | 0 .../app/common/views/components/messaging.vue | 0 .../web/app/common/views/components/nav.vue | 0 .../common/views/components/othello.game.vue | 0 .../views/components/othello.gameroom.vue | 0 .../common/views/components/othello.room.vue | 0 .../app/common/views/components/othello.vue | 0 .../common/views/components/poll-editor.vue | 0 .../web/app/common/views/components/poll.vue | 0 .../app/common/views/components/post-html.ts | 0 .../app/common/views/components/post-menu.vue | 0 .../common/views/components/reaction-icon.vue | 0 .../views/components/reaction-picker.vue | 0 .../views/components/reactions-viewer.vue | 0 .../app/common/views/components/signin.vue | 0 .../app/common/views/components/signup.vue | 0 .../views/components/special-message.vue | 0 .../views/components/stream-indicator.vue | 0 .../app/common/views/components/switch.vue | 0 .../web/app/common/views/components/time.vue | 0 .../web/app/common/views/components/timer.vue | 0 .../views/components/twitter-setting.vue | 0 .../app/common/views/components/uploader.vue | 0 .../common/views/components/url-preview.vue | 0 .../web/app/common/views/components/url.vue | 0 .../views/components/welcome-timeline.vue | 0 .../common/views/directives/autocomplete.ts | 0 .../web/app/common/views/directives/index.ts | 0 .../web/app/common/views/filters/bytes.ts | 0 .../web/app/common/views/filters/index.ts | 0 .../web/app/common/views/filters/number.ts | 0 .../app/common/views/widgets/access-log.vue | 0 .../app/common/views/widgets/broadcast.vue | 0 .../web/app/common/views/widgets/calendar.vue | 0 .../web/app/common/views/widgets/donation.vue | 0 .../web/app/common/views/widgets/index.ts | 0 .../web/app/common/views/widgets/nav.vue | 0 .../app/common/views/widgets/photo-stream.vue | 0 .../web/app/common/views/widgets/rss.vue | 0 .../views/widgets/server.cpu-memory.vue | 0 .../app/common/views/widgets/server.cpu.vue | 0 .../app/common/views/widgets/server.disk.vue | 0 .../app/common/views/widgets/server.info.vue | 0 .../common/views/widgets/server.memory.vue | 0 .../app/common/views/widgets/server.pie.vue | 0 .../common/views/widgets/server.uptimes.vue | 0 .../web/app/common/views/widgets/server.vue | 0 .../app/common/views/widgets/slideshow.vue | 0 .../web/app/common/views/widgets/tips.vue | 0 .../web/app/common/views/widgets/version.vue | 0 src/{ => server}/web/app/config.ts | 0 .../web/app/desktop/api/choose-drive-file.ts | 0 .../app/desktop/api/choose-drive-folder.ts | 0 .../web/app/desktop/api/contextmenu.ts | 0 .../web/app/desktop/api/dialog.ts | 0 src/{ => server}/web/app/desktop/api/input.ts | 0 .../web/app/desktop/api/notify.ts | 0 src/{ => server}/web/app/desktop/api/post.ts | 0 .../web/app/desktop/api/update-avatar.ts | 0 .../web/app/desktop/api/update-banner.ts | 0 .../web/app/desktop/assets/grid.svg | 0 .../app/desktop/assets/header-logo-white.svg | 0 .../web/app/desktop/assets/header-logo.svg | 0 .../web/app/desktop/assets/index.jpg | Bin .../web/app/desktop/assets/remove.png | Bin src/{ => server}/web/app/desktop/script.ts | 0 src/{ => server}/web/app/desktop/style.styl | 0 src/{ => server}/web/app/desktop/ui.styl | 0 .../views/components/activity.calendar.vue | 0 .../views/components/activity.chart.vue | 0 .../app/desktop/views/components/activity.vue | 0 .../desktop/views/components/analog-clock.vue | 0 .../app/desktop/views/components/calendar.vue | 0 .../choose-file-from-drive-window.vue | 0 .../choose-folder-from-drive-window.vue | 0 .../views/components/context-menu.menu.vue | 0 .../desktop/views/components/context-menu.vue | 0 .../desktop/views/components/crop-window.vue | 0 .../app/desktop/views/components/dialog.vue | 0 .../desktop/views/components/drive-window.vue | 0 .../desktop/views/components/drive.file.vue | 0 .../desktop/views/components/drive.folder.vue | 0 .../views/components/drive.nav-folder.vue | 0 .../app/desktop/views/components/drive.vue | 0 .../views/components/ellipsis-icon.vue | 0 .../views/components/follow-button.vue | 0 .../views/components/followers-window.vue | 0 .../desktop/views/components/followers.vue | 0 .../views/components/following-window.vue | 0 .../desktop/views/components/following.vue | 0 .../views/components/friends-maker.vue | 0 .../desktop/views/components/game-window.vue | 0 .../web/app/desktop/views/components/home.vue | 0 .../web/app/desktop/views/components/index.ts | 0 .../desktop/views/components/input-dialog.vue | 0 .../views/components/media-image-dialog.vue | 0 .../desktop/views/components/media-image.vue | 0 .../views/components/media-video-dialog.vue | 0 .../desktop/views/components/media-video.vue | 0 .../app/desktop/views/components/mentions.vue | 0 .../components/messaging-room-window.vue | 0 .../views/components/messaging-window.vue | 0 .../views/components/notifications.vue | 0 .../views/components/post-detail.sub.vue | 0 .../desktop/views/components/post-detail.vue | 0 .../views/components/post-form-window.vue | 0 .../desktop/views/components/post-form.vue | 0 .../desktop/views/components/post-preview.vue | 0 .../views/components/posts.post.sub.vue | 0 .../desktop/views/components/posts.post.vue | 0 .../app/desktop/views/components/posts.vue | 0 .../views/components/progress-dialog.vue | 0 .../views/components/repost-form-window.vue | 0 .../desktop/views/components/repost-form.vue | 0 .../views/components/settings-window.vue | 0 .../desktop/views/components/settings.2fa.vue | 0 .../desktop/views/components/settings.api.vue | 0 .../views/components/settings.apps.vue | 0 .../views/components/settings.drive.vue | 0 .../views/components/settings.mute.vue | 0 .../views/components/settings.password.vue | 0 .../views/components/settings.profile.vue | 0 .../views/components/settings.signins.vue | 0 .../app/desktop/views/components/settings.vue | 0 .../views/components/sub-post-content.vue | 0 .../desktop/views/components/taskmanager.vue | 0 .../app/desktop/views/components/timeline.vue | 0 .../views/components/ui-notification.vue | 0 .../views/components/ui.header.account.vue | 0 .../views/components/ui.header.clock.vue | 0 .../views/components/ui.header.nav.vue | 0 .../components/ui.header.notifications.vue | 0 .../views/components/ui.header.post.vue | 0 .../views/components/ui.header.search.vue | 0 .../desktop/views/components/ui.header.vue | 0 .../web/app/desktop/views/components/ui.vue | 0 .../desktop/views/components/user-preview.vue | 0 .../views/components/users-list.item.vue | 0 .../desktop/views/components/users-list.vue | 0 .../views/components/widget-container.vue | 0 .../app/desktop/views/components/window.vue | 0 .../web/app/desktop/views/directives/index.ts | 0 .../desktop/views/directives/user-preview.ts | 0 .../web/app/desktop/views/pages/drive.vue | 0 .../desktop/views/pages/home-customize.vue | 0 .../web/app/desktop/views/pages/home.vue | 0 .../web/app/desktop/views/pages/index.vue | 0 .../desktop/views/pages/messaging-room.vue | 0 .../web/app/desktop/views/pages/othello.vue | 0 .../web/app/desktop/views/pages/post.vue | 0 .../web/app/desktop/views/pages/search.vue | 0 .../app/desktop/views/pages/selectdrive.vue | 0 .../pages/user/user.followers-you-know.vue | 0 .../desktop/views/pages/user/user.friends.vue | 0 .../desktop/views/pages/user/user.header.vue | 0 .../desktop/views/pages/user/user.home.vue | 0 .../desktop/views/pages/user/user.photos.vue | 0 .../desktop/views/pages/user/user.profile.vue | 0 .../views/pages/user/user.timeline.vue | 0 .../web/app/desktop/views/pages/user/user.vue | 0 .../web/app/desktop/views/pages/welcome.vue | 0 .../app/desktop/views/widgets/activity.vue | 0 .../views/widgets/channel.channel.form.vue | 0 .../views/widgets/channel.channel.post.vue | 0 .../desktop/views/widgets/channel.channel.vue | 0 .../web/app/desktop/views/widgets/channel.vue | 0 .../web/app/desktop/views/widgets/index.ts | 0 .../app/desktop/views/widgets/messaging.vue | 0 .../desktop/views/widgets/notifications.vue | 0 .../web/app/desktop/views/widgets/polls.vue | 0 .../app/desktop/views/widgets/post-form.vue | 0 .../web/app/desktop/views/widgets/profile.vue | 0 .../app/desktop/views/widgets/timemachine.vue | 0 .../web/app/desktop/views/widgets/trends.vue | 0 .../web/app/desktop/views/widgets/users.vue | 0 src/{ => server}/web/app/dev/script.ts | 0 src/{ => server}/web/app/dev/style.styl | 0 src/{ => server}/web/app/dev/views/app.vue | 0 src/{ => server}/web/app/dev/views/apps.vue | 0 src/{ => server}/web/app/dev/views/index.vue | 0 .../web/app/dev/views/new-app.vue | 0 src/{ => server}/web/app/dev/views/ui.vue | 0 src/{ => server}/web/app/init.css | 0 src/{ => server}/web/app/init.ts | 0 .../web/app/mobile/api/choose-drive-file.ts | 0 .../web/app/mobile/api/choose-drive-folder.ts | 0 src/{ => server}/web/app/mobile/api/dialog.ts | 0 src/{ => server}/web/app/mobile/api/input.ts | 0 src/{ => server}/web/app/mobile/api/notify.ts | 0 src/{ => server}/web/app/mobile/api/post.ts | 0 src/{ => server}/web/app/mobile/script.ts | 0 src/{ => server}/web/app/mobile/style.styl | 0 .../app/mobile/views/components/activity.vue | 0 .../views/components/drive-file-chooser.vue | 0 .../views/components/drive-folder-chooser.vue | 0 .../views/components/drive.file-detail.vue | 0 .../mobile/views/components/drive.file.vue | 0 .../mobile/views/components/drive.folder.vue | 0 .../web/app/mobile/views/components/drive.vue | 0 .../mobile/views/components/follow-button.vue | 0 .../mobile/views/components/friends-maker.vue | 0 .../web/app/mobile/views/components/index.ts | 0 .../mobile/views/components/media-image.vue | 0 .../mobile/views/components/media-video.vue | 0 .../views/components/notification-preview.vue | 0 .../mobile/views/components/notification.vue | 0 .../mobile/views/components/notifications.vue | 0 .../app/mobile/views/components/notify.vue | 0 .../app/mobile/views/components/post-card.vue | 0 .../views/components/post-detail.sub.vue | 0 .../mobile/views/components/post-detail.vue | 0 .../app/mobile/views/components/post-form.vue | 0 .../mobile/views/components/post-preview.vue | 0 .../app/mobile/views/components/post.sub.vue | 0 .../web/app/mobile/views/components/post.vue | 0 .../web/app/mobile/views/components/posts.vue | 0 .../views/components/sub-post-content.vue | 0 .../app/mobile/views/components/timeline.vue | 0 .../app/mobile/views/components/ui.header.vue | 0 .../app/mobile/views/components/ui.nav.vue | 0 .../web/app/mobile/views/components/ui.vue | 0 .../app/mobile/views/components/user-card.vue | 0 .../mobile/views/components/user-preview.vue | 0 .../mobile/views/components/user-timeline.vue | 0 .../mobile/views/components/users-list.vue | 0 .../views/components/widget-container.vue | 0 .../web/app/mobile/views/directives/index.ts | 0 .../mobile/views/directives/user-preview.ts | 0 .../web/app/mobile/views/pages/drive.vue | 0 .../web/app/mobile/views/pages/followers.vue | 0 .../web/app/mobile/views/pages/following.vue | 0 .../web/app/mobile/views/pages/home.vue | 0 .../web/app/mobile/views/pages/index.vue | 0 .../app/mobile/views/pages/messaging-room.vue | 0 .../web/app/mobile/views/pages/messaging.vue | 0 .../app/mobile/views/pages/notifications.vue | 0 .../web/app/mobile/views/pages/othello.vue | 0 .../web/app/mobile/views/pages/post.vue | 0 .../mobile/views/pages/profile-setting.vue | 0 .../web/app/mobile/views/pages/search.vue | 0 .../app/mobile/views/pages/selectdrive.vue | 0 .../web/app/mobile/views/pages/settings.vue | 0 .../web/app/mobile/views/pages/signup.vue | 0 .../web/app/mobile/views/pages/user.vue | 0 .../pages/user/home.followers-you-know.vue | 0 .../mobile/views/pages/user/home.friends.vue | 0 .../mobile/views/pages/user/home.photos.vue | 0 .../mobile/views/pages/user/home.posts.vue | 0 .../web/app/mobile/views/pages/user/home.vue | 0 .../web/app/mobile/views/pages/welcome.vue | 0 .../web/app/mobile/views/widgets/activity.vue | 0 .../web/app/mobile/views/widgets/index.ts | 0 .../web/app/mobile/views/widgets/profile.vue | 0 src/{ => server}/web/app/reset.styl | 0 src/{ => server}/web/app/safe.js | 0 src/{ => server}/web/app/stats/style.styl | 0 src/{ => server}/web/app/stats/tags/index.tag | 0 src/{ => server}/web/app/stats/tags/index.ts | 0 src/{ => server}/web/app/status/style.styl | 0 .../web/app/status/tags/index.tag | 0 src/{ => server}/web/app/status/tags/index.ts | 0 src/{ => server}/web/app/sw.js | 0 src/{ => server}/web/app/tsconfig.json | 0 src/{ => server}/web/app/v.d.ts | 0 src/{ => server}/web/assets/404.js | 0 .../web/assets/code-highlight.css | 0 src/{ => server}/web/assets/error.jpg | Bin src/{ => server}/web/assets/favicon.ico | Bin src/{ => server}/web/assets/label.svg | 0 src/{ => server}/web/assets/manifest.json | 0 src/{ => server}/web/assets/message.mp3 | Bin .../web/assets/othello-put-me.mp3 | Bin .../web/assets/othello-put-you.mp3 | Bin src/{ => server}/web/assets/post.mp3 | Bin .../web/assets/reactions/angry.png | Bin .../web/assets/reactions/confused.png | Bin .../web/assets/reactions/congrats.png | Bin src/{ => server}/web/assets/reactions/hmm.png | Bin .../web/assets/reactions/laugh.png | Bin .../web/assets/reactions/like.png | Bin .../web/assets/reactions/love.png | Bin .../web/assets/reactions/pudding.png | Bin .../web/assets/reactions/surprise.png | Bin src/{ => server}/web/assets/recover.html | 0 src/{ => server}/web/assets/title.svg | 0 src/{ => server}/web/assets/unread.svg | 0 src/{ => server}/web/assets/welcome-bg.svg | 0 src/{ => server}/web/assets/welcome-fg.svg | 0 src/{ => server}/web/const.styl | 2 +- src/{ => server}/web/docs/about.en.pug | 0 src/{ => server}/web/docs/about.ja.pug | 0 src/{ => server}/web/docs/api.ja.pug | 0 .../web/docs/api/endpoints/posts/create.yaml | 0 .../docs/api/endpoints/posts/timeline.yaml | 0 .../web/docs/api/endpoints/style.styl | 0 .../web/docs/api/endpoints/view.pug | 0 .../web/docs/api/entities/drive-file.yaml | 0 .../web/docs/api/entities/post.yaml | 0 .../web/docs/api/entities/style.styl | 0 .../web/docs/api/entities/user.yaml | 0 .../web/docs/api/entities/view.pug | 0 src/{ => server}/web/docs/api/gulpfile.ts | 24 +++++------ src/{ => server}/web/docs/api/mixins.pug | 0 src/{ => server}/web/docs/api/style.styl | 0 src/{ => server}/web/docs/gulpfile.ts | 16 ++++---- src/{ => server}/web/docs/index.en.pug | 0 src/{ => server}/web/docs/index.ja.pug | 0 src/{ => server}/web/docs/layout.pug | 0 src/{ => server}/web/docs/license.en.pug | 0 src/{ => server}/web/docs/license.ja.pug | 0 src/{ => server}/web/docs/mute.ja.pug | 0 src/{ => server}/web/docs/search.ja.pug | 0 src/{ => server}/web/docs/server.ts | 0 src/{ => server}/web/docs/style.styl | 0 src/{ => server}/web/docs/tou.ja.pug | 0 src/{ => server}/web/docs/ui.styl | 0 src/{ => server}/web/docs/vars.ts | 16 ++++---- src/{ => server}/web/element.scss | 2 +- src/{ => server}/web/server.ts | 0 src/{ => server}/web/service/url-preview.ts | 0 src/{ => server}/web/style.styl | 0 src/tools/analysis/core.ts | 2 +- src/tools/analysis/extract-user-domains.ts | 6 +-- src/tools/analysis/extract-user-keywords.ts | 6 +-- .../analysis/predict-all-post-category.ts | 2 +- src/tools/analysis/predict-user-interst.ts | 4 +- test/api.js | 2 +- test/text.js | 4 +- tsconfig.json | 2 +- webpack.config.ts | 30 +++++++------- 582 files changed, 246 insertions(+), 188 deletions(-) rename src/{common => }/build/fa.ts (100%) rename src/{common => }/build/i18n.ts (96%) rename src/{common => }/build/license.ts (72%) create mode 100644 src/parse-opt.ts create mode 100644 src/processor/index.ts create mode 100644 src/processor/report-github-failure.ts create mode 100644 src/queue.ts rename src/{ => server}/api/api-handler.ts (100%) rename src/{ => server}/api/authenticate.ts (100%) rename src/{ => server}/api/bot/core.ts (100%) rename src/{ => server}/api/bot/interfaces/line.ts (98%) rename src/{ => server}/api/common/drive/add-file.ts (99%) rename src/{ => server}/api/common/drive/upload_from_url.ts (100%) rename src/{ => server}/api/common/generate-native-user-token.ts (100%) rename src/{ => server}/api/common/get-friends.ts (100%) rename src/{ => server}/api/common/get-host-lower.ts (100%) rename src/{ => server}/api/common/is-native-token.ts (100%) rename src/{ => server}/api/common/notify.ts (100%) rename src/{ => server}/api/common/push-sw.ts (97%) rename src/{ => server}/api/common/read-messaging-message.ts (100%) rename src/{ => server}/api/common/read-notification.ts (100%) rename src/{ => server}/api/common/signin.ts (92%) rename src/{ => server}/api/common/text/core/syntax-highlighter.ts (100%) rename src/{ => server}/api/common/text/elements/bold.ts (100%) rename src/{ => server}/api/common/text/elements/code.ts (100%) rename src/{ => server}/api/common/text/elements/emoji.ts (100%) rename src/{ => server}/api/common/text/elements/hashtag.ts (100%) rename src/{ => server}/api/common/text/elements/inline-code.ts (100%) rename src/{ => server}/api/common/text/elements/link.ts (100%) rename src/{ => server}/api/common/text/elements/mention.ts (100%) rename src/{ => server}/api/common/text/elements/quote.ts (100%) rename src/{ => server}/api/common/text/elements/url.ts (100%) rename src/{ => server}/api/common/text/index.ts (100%) rename src/{ => server}/api/common/watch-post.ts (100%) rename src/{ => server}/api/endpoints.ts (100%) rename src/{ => server}/api/endpoints/aggregation/posts.ts (100%) rename src/{ => server}/api/endpoints/aggregation/posts/reaction.ts (100%) rename src/{ => server}/api/endpoints/aggregation/posts/reactions.ts (100%) rename src/{ => server}/api/endpoints/aggregation/posts/reply.ts (100%) rename src/{ => server}/api/endpoints/aggregation/posts/repost.ts (100%) rename src/{ => server}/api/endpoints/aggregation/users.ts (100%) rename src/{ => server}/api/endpoints/aggregation/users/activity.ts (100%) rename src/{ => server}/api/endpoints/aggregation/users/followers.ts (100%) rename src/{ => server}/api/endpoints/aggregation/users/following.ts (100%) rename src/{ => server}/api/endpoints/aggregation/users/post.ts (100%) rename src/{ => server}/api/endpoints/aggregation/users/reaction.ts (100%) rename src/{ => server}/api/endpoints/app/create.ts (100%) rename src/{ => server}/api/endpoints/app/name_id/available.ts (100%) rename src/{ => server}/api/endpoints/app/show.ts (100%) rename src/{ => server}/api/endpoints/auth/accept.ts (100%) rename src/{ => server}/api/endpoints/auth/session/generate.ts (97%) rename src/{ => server}/api/endpoints/auth/session/show.ts (100%) rename src/{ => server}/api/endpoints/auth/session/userkey.ts (100%) rename src/{ => server}/api/endpoints/channels.ts (100%) rename src/{ => server}/api/endpoints/channels/create.ts (100%) rename src/{ => server}/api/endpoints/channels/posts.ts (100%) rename src/{ => server}/api/endpoints/channels/show.ts (100%) rename src/{ => server}/api/endpoints/channels/unwatch.ts (100%) rename src/{ => server}/api/endpoints/channels/watch.ts (100%) rename src/{ => server}/api/endpoints/drive.ts (100%) rename src/{ => server}/api/endpoints/drive/files.ts (100%) rename src/{ => server}/api/endpoints/drive/files/create.ts (100%) rename src/{ => server}/api/endpoints/drive/files/find.ts (100%) rename src/{ => server}/api/endpoints/drive/files/show.ts (100%) rename src/{ => server}/api/endpoints/drive/files/update.ts (100%) rename src/{ => server}/api/endpoints/drive/files/upload_from_url.ts (100%) rename src/{ => server}/api/endpoints/drive/folders.ts (100%) rename src/{ => server}/api/endpoints/drive/folders/create.ts (100%) rename src/{ => server}/api/endpoints/drive/folders/find.ts (100%) rename src/{ => server}/api/endpoints/drive/folders/show.ts (100%) rename src/{ => server}/api/endpoints/drive/folders/update.ts (100%) rename src/{ => server}/api/endpoints/drive/stream.ts (100%) rename src/{ => server}/api/endpoints/following/create.ts (100%) rename src/{ => server}/api/endpoints/following/delete.ts (100%) rename src/{ => server}/api/endpoints/i.ts (100%) rename src/{ => server}/api/endpoints/i/2fa/done.ts (100%) rename src/{ => server}/api/endpoints/i/2fa/register.ts (96%) rename src/{ => server}/api/endpoints/i/2fa/unregister.ts (100%) rename src/{ => server}/api/endpoints/i/appdata/get.ts (100%) rename src/{ => server}/api/endpoints/i/appdata/set.ts (100%) rename src/{ => server}/api/endpoints/i/authorized_apps.ts (100%) rename src/{ => server}/api/endpoints/i/change_password.ts (100%) rename src/{ => server}/api/endpoints/i/favorites.ts (100%) rename src/{ => server}/api/endpoints/i/notifications.ts (100%) rename src/{ => server}/api/endpoints/i/pin.ts (100%) rename src/{ => server}/api/endpoints/i/regenerate_token.ts (100%) rename src/{ => server}/api/endpoints/i/signin_history.ts (100%) rename src/{ => server}/api/endpoints/i/update.ts (98%) rename src/{ => server}/api/endpoints/i/update_client_setting.ts (100%) rename src/{ => server}/api/endpoints/i/update_home.ts (100%) rename src/{ => server}/api/endpoints/i/update_mobile_home.ts (100%) rename src/{ => server}/api/endpoints/messaging/history.ts (100%) rename src/{ => server}/api/endpoints/messaging/messages.ts (100%) rename src/{ => server}/api/endpoints/messaging/messages/create.ts (99%) rename src/{ => server}/api/endpoints/messaging/unread.ts (100%) rename src/{ => server}/api/endpoints/meta.ts (94%) rename src/{ => server}/api/endpoints/mute/create.ts (100%) rename src/{ => server}/api/endpoints/mute/delete.ts (100%) rename src/{ => server}/api/endpoints/mute/list.ts (100%) rename src/{ => server}/api/endpoints/my/apps.ts (100%) rename src/{ => server}/api/endpoints/notifications/get_unread_count.ts (100%) rename src/{ => server}/api/endpoints/notifications/mark_as_read_all.ts (100%) rename src/{ => server}/api/endpoints/othello/games.ts (100%) rename src/{ => server}/api/endpoints/othello/games/show.ts (100%) rename src/{ => server}/api/endpoints/othello/invitations.ts (100%) rename src/{ => server}/api/endpoints/othello/match.ts (100%) rename src/{ => server}/api/endpoints/othello/match/cancel.ts (100%) rename src/{ => server}/api/endpoints/posts.ts (100%) rename src/{ => server}/api/endpoints/posts/categorize.ts (100%) rename src/{ => server}/api/endpoints/posts/context.ts (100%) rename src/{ => server}/api/endpoints/posts/create.ts (99%) rename src/{ => server}/api/endpoints/posts/favorites/create.ts (100%) rename src/{ => server}/api/endpoints/posts/favorites/delete.ts (100%) rename src/{ => server}/api/endpoints/posts/mentions.ts (100%) rename src/{ => server}/api/endpoints/posts/polls/recommendation.ts (100%) rename src/{ => server}/api/endpoints/posts/polls/vote.ts (100%) rename src/{ => server}/api/endpoints/posts/reactions.ts (100%) rename src/{ => server}/api/endpoints/posts/reactions/create.ts (100%) rename src/{ => server}/api/endpoints/posts/reactions/delete.ts (100%) rename src/{ => server}/api/endpoints/posts/replies.ts (100%) rename src/{ => server}/api/endpoints/posts/reposts.ts (100%) rename src/{ => server}/api/endpoints/posts/search.ts (100%) rename src/{ => server}/api/endpoints/posts/show.ts (100%) rename src/{ => server}/api/endpoints/posts/timeline.ts (100%) rename src/{ => server}/api/endpoints/posts/trend.ts (100%) rename src/{ => server}/api/endpoints/stats.ts (100%) rename src/{ => server}/api/endpoints/sw/register.ts (100%) rename src/{ => server}/api/endpoints/username/available.ts (100%) rename src/{ => server}/api/endpoints/users.ts (100%) rename src/{ => server}/api/endpoints/users/followers.ts (100%) rename src/{ => server}/api/endpoints/users/following.ts (100%) rename src/{ => server}/api/endpoints/users/get_frequently_replied_users.ts (100%) rename src/{ => server}/api/endpoints/users/posts.ts (100%) rename src/{ => server}/api/endpoints/users/recommendation.ts (100%) rename src/{ => server}/api/endpoints/users/search.ts (98%) rename src/{ => server}/api/endpoints/users/search_by_username.ts (100%) rename src/{ => server}/api/endpoints/users/show.ts (100%) rename src/{ => server}/api/event.ts (98%) rename src/{ => server}/api/limitter.ts (97%) rename src/{ => server}/api/models/access-token.ts (86%) rename src/{ => server}/api/models/app.ts (96%) rename src/{ => server}/api/models/appdata.ts (63%) rename src/{ => server}/api/models/auth-session.ts (95%) rename src/{ => server}/api/models/channel-watching.ts (66%) rename src/{ => server}/api/models/channel.ts (97%) rename src/{ => server}/api/models/drive-file.ts (96%) rename src/{ => server}/api/models/drive-folder.ts (97%) rename src/{ => server}/api/models/drive-tag.ts (64%) rename src/{ => server}/api/models/favorite.ts (64%) rename src/{ => server}/api/models/following.ts (64%) rename src/{ => server}/api/models/messaging-history.ts (67%) rename src/{ => server}/api/models/messaging-message.ts (97%) rename src/{ => server}/api/models/meta.ts (74%) rename src/{ => server}/api/models/mute.ts (62%) rename src/{ => server}/api/models/notification.ts (98%) rename src/{ => server}/api/models/othello-game.ts (98%) rename src/{ => server}/api/models/othello-matching.ts (96%) rename src/{ => server}/api/models/poll-vote.ts (64%) rename src/{ => server}/api/models/post-reaction.ts (96%) rename src/{ => server}/api/models/post-watching.ts (65%) rename src/{ => server}/api/models/post.ts (99%) rename src/{ => server}/api/models/signin.ts (93%) rename src/{ => server}/api/models/sw-subscription.ts (66%) rename src/{ => server}/api/models/user.ts (99%) rename src/{ => server}/api/private/signin.ts (98%) rename src/{ => server}/api/private/signup.ts (96%) rename src/{ => server}/api/reply.ts (100%) rename src/{ => server}/api/server.ts (100%) rename src/{ => server}/api/service/github.ts (77%) rename src/{ => server}/api/service/twitter.ts (98%) rename src/{ => server}/api/stream/channel.ts (100%) rename src/{ => server}/api/stream/drive.ts (100%) rename src/{ => server}/api/stream/home.ts (100%) rename src/{ => server}/api/stream/messaging-index.ts (100%) rename src/{ => server}/api/stream/messaging.ts (100%) rename src/{ => server}/api/stream/othello-game.ts (100%) rename src/{ => server}/api/stream/othello.ts (100%) rename src/{ => server}/api/stream/requests.ts (100%) rename src/{ => server}/api/stream/server.ts (100%) rename src/{ => server}/api/streaming.ts (98%) rename src/{ => server}/common/get-notification-summary.ts (100%) rename src/{ => server}/common/get-post-summary.ts (100%) rename src/{ => server}/common/get-reaction-emoji.ts (100%) rename src/{ => server}/common/othello/ai/back.ts (99%) rename src/{ => server}/common/othello/ai/front.ts (99%) rename src/{ => server}/common/othello/ai/index.ts (100%) rename src/{ => server}/common/othello/core.ts (100%) rename src/{ => server}/common/othello/maps.ts (100%) rename src/{ => server}/common/user/get-acct.ts (100%) rename src/{ => server}/common/user/get-summary.ts (100%) rename src/{ => server}/common/user/parse-acct.ts (100%) rename src/{ => server}/file/assets/avatar.jpg (100%) rename src/{ => server}/file/assets/bad-egg.png (100%) rename src/{ => server}/file/assets/dummy.png (100%) rename src/{ => server}/file/assets/not-an-image.png (100%) rename src/{ => server}/file/assets/thumbnail-not-available.png (100%) rename src/{ => server}/file/server.ts (100%) rename src/{server.ts => server/index.ts} (77%) rename src/{ => server}/log-request.ts (100%) rename src/{ => server}/web/app/animation.styl (100%) rename src/{ => server}/web/app/app.styl (100%) rename src/{ => server}/web/app/app.vue (100%) rename src/{ => server}/web/app/auth/assets/logo.svg (100%) rename src/{ => server}/web/app/auth/script.ts (100%) rename src/{ => server}/web/app/auth/style.styl (100%) rename src/{ => server}/web/app/auth/views/form.vue (100%) rename src/{ => server}/web/app/auth/views/index.vue (100%) rename src/{ => server}/web/app/base.pug (76%) rename src/{ => server}/web/app/boot.js (100%) rename src/{ => server}/web/app/ch/script.ts (100%) rename src/{ => server}/web/app/ch/style.styl (100%) rename src/{ => server}/web/app/ch/tags/channel.tag (100%) rename src/{ => server}/web/app/ch/tags/header.tag (100%) rename src/{ => server}/web/app/ch/tags/index.tag (100%) rename src/{ => server}/web/app/ch/tags/index.ts (100%) rename src/{ => server}/web/app/common/define-widget.ts (100%) rename src/{ => server}/web/app/common/mios.ts (100%) rename src/{ => server}/web/app/common/scripts/check-for-update.ts (100%) rename src/{ => server}/web/app/common/scripts/compose-notification.ts (100%) rename src/{ => server}/web/app/common/scripts/contains.ts (100%) rename src/{ => server}/web/app/common/scripts/copy-to-clipboard.ts (100%) rename src/{ => server}/web/app/common/scripts/date-stringify.ts (100%) rename src/{ => server}/web/app/common/scripts/fuck-ad-block.ts (100%) rename src/{ => server}/web/app/common/scripts/gcd.ts (100%) rename src/{ => server}/web/app/common/scripts/get-kao.ts (100%) rename src/{ => server}/web/app/common/scripts/get-median.ts (100%) rename src/{ => server}/web/app/common/scripts/loading.ts (100%) rename src/{ => server}/web/app/common/scripts/parse-search-query.ts (100%) rename src/{ => server}/web/app/common/scripts/streaming/channel.ts (100%) rename src/{ => server}/web/app/common/scripts/streaming/drive.ts (100%) rename src/{ => server}/web/app/common/scripts/streaming/home.ts (100%) rename src/{ => server}/web/app/common/scripts/streaming/messaging-index.ts (100%) rename src/{ => server}/web/app/common/scripts/streaming/messaging.ts (100%) rename src/{ => server}/web/app/common/scripts/streaming/othello-game.ts (100%) rename src/{ => server}/web/app/common/scripts/streaming/othello.ts (100%) rename src/{ => server}/web/app/common/scripts/streaming/requests.ts (100%) rename src/{ => server}/web/app/common/scripts/streaming/server.ts (100%) rename src/{ => server}/web/app/common/scripts/streaming/stream-manager.ts (100%) rename src/{ => server}/web/app/common/scripts/streaming/stream.ts (100%) rename src/{ => server}/web/app/common/views/components/autocomplete.vue (100%) rename src/{ => server}/web/app/common/views/components/connect-failed.troubleshooter.vue (100%) rename src/{ => server}/web/app/common/views/components/connect-failed.vue (100%) rename src/{ => server}/web/app/common/views/components/ellipsis.vue (100%) rename src/{ => server}/web/app/common/views/components/file-type-icon.vue (100%) rename src/{ => server}/web/app/common/views/components/forkit.vue (100%) rename src/{ => server}/web/app/common/views/components/index.ts (100%) rename src/{ => server}/web/app/common/views/components/media-list.vue (100%) rename src/{ => server}/web/app/common/views/components/messaging-room.form.vue (100%) rename src/{ => server}/web/app/common/views/components/messaging-room.message.vue (100%) rename src/{ => server}/web/app/common/views/components/messaging-room.vue (100%) rename src/{ => server}/web/app/common/views/components/messaging.vue (100%) rename src/{ => server}/web/app/common/views/components/nav.vue (100%) rename src/{ => server}/web/app/common/views/components/othello.game.vue (100%) rename src/{ => server}/web/app/common/views/components/othello.gameroom.vue (100%) rename src/{ => server}/web/app/common/views/components/othello.room.vue (100%) rename src/{ => server}/web/app/common/views/components/othello.vue (100%) rename src/{ => server}/web/app/common/views/components/poll-editor.vue (100%) rename src/{ => server}/web/app/common/views/components/poll.vue (100%) rename src/{ => server}/web/app/common/views/components/post-html.ts (100%) rename src/{ => server}/web/app/common/views/components/post-menu.vue (100%) rename src/{ => server}/web/app/common/views/components/reaction-icon.vue (100%) rename src/{ => server}/web/app/common/views/components/reaction-picker.vue (100%) rename src/{ => server}/web/app/common/views/components/reactions-viewer.vue (100%) rename src/{ => server}/web/app/common/views/components/signin.vue (100%) rename src/{ => server}/web/app/common/views/components/signup.vue (100%) rename src/{ => server}/web/app/common/views/components/special-message.vue (100%) rename src/{ => server}/web/app/common/views/components/stream-indicator.vue (100%) rename src/{ => server}/web/app/common/views/components/switch.vue (100%) rename src/{ => server}/web/app/common/views/components/time.vue (100%) rename src/{ => server}/web/app/common/views/components/timer.vue (100%) rename src/{ => server}/web/app/common/views/components/twitter-setting.vue (100%) rename src/{ => server}/web/app/common/views/components/uploader.vue (100%) rename src/{ => server}/web/app/common/views/components/url-preview.vue (100%) rename src/{ => server}/web/app/common/views/components/url.vue (100%) rename src/{ => server}/web/app/common/views/components/welcome-timeline.vue (100%) rename src/{ => server}/web/app/common/views/directives/autocomplete.ts (100%) rename src/{ => server}/web/app/common/views/directives/index.ts (100%) rename src/{ => server}/web/app/common/views/filters/bytes.ts (100%) rename src/{ => server}/web/app/common/views/filters/index.ts (100%) rename src/{ => server}/web/app/common/views/filters/number.ts (100%) rename src/{ => server}/web/app/common/views/widgets/access-log.vue (100%) rename src/{ => server}/web/app/common/views/widgets/broadcast.vue (100%) rename src/{ => server}/web/app/common/views/widgets/calendar.vue (100%) rename src/{ => server}/web/app/common/views/widgets/donation.vue (100%) rename src/{ => server}/web/app/common/views/widgets/index.ts (100%) rename src/{ => server}/web/app/common/views/widgets/nav.vue (100%) rename src/{ => server}/web/app/common/views/widgets/photo-stream.vue (100%) rename src/{ => server}/web/app/common/views/widgets/rss.vue (100%) rename src/{ => server}/web/app/common/views/widgets/server.cpu-memory.vue (100%) rename src/{ => server}/web/app/common/views/widgets/server.cpu.vue (100%) rename src/{ => server}/web/app/common/views/widgets/server.disk.vue (100%) rename src/{ => server}/web/app/common/views/widgets/server.info.vue (100%) rename src/{ => server}/web/app/common/views/widgets/server.memory.vue (100%) rename src/{ => server}/web/app/common/views/widgets/server.pie.vue (100%) rename src/{ => server}/web/app/common/views/widgets/server.uptimes.vue (100%) rename src/{ => server}/web/app/common/views/widgets/server.vue (100%) rename src/{ => server}/web/app/common/views/widgets/slideshow.vue (100%) rename src/{ => server}/web/app/common/views/widgets/tips.vue (100%) rename src/{ => server}/web/app/common/views/widgets/version.vue (100%) rename src/{ => server}/web/app/config.ts (100%) rename src/{ => server}/web/app/desktop/api/choose-drive-file.ts (100%) rename src/{ => server}/web/app/desktop/api/choose-drive-folder.ts (100%) rename src/{ => server}/web/app/desktop/api/contextmenu.ts (100%) rename src/{ => server}/web/app/desktop/api/dialog.ts (100%) rename src/{ => server}/web/app/desktop/api/input.ts (100%) rename src/{ => server}/web/app/desktop/api/notify.ts (100%) rename src/{ => server}/web/app/desktop/api/post.ts (100%) rename src/{ => server}/web/app/desktop/api/update-avatar.ts (100%) rename src/{ => server}/web/app/desktop/api/update-banner.ts (100%) rename src/{ => server}/web/app/desktop/assets/grid.svg (100%) rename src/{ => server}/web/app/desktop/assets/header-logo-white.svg (100%) rename src/{ => server}/web/app/desktop/assets/header-logo.svg (100%) rename src/{ => server}/web/app/desktop/assets/index.jpg (100%) rename src/{ => server}/web/app/desktop/assets/remove.png (100%) rename src/{ => server}/web/app/desktop/script.ts (100%) rename src/{ => server}/web/app/desktop/style.styl (100%) rename src/{ => server}/web/app/desktop/ui.styl (100%) rename src/{ => server}/web/app/desktop/views/components/activity.calendar.vue (100%) rename src/{ => server}/web/app/desktop/views/components/activity.chart.vue (100%) rename src/{ => server}/web/app/desktop/views/components/activity.vue (100%) rename src/{ => server}/web/app/desktop/views/components/analog-clock.vue (100%) rename src/{ => server}/web/app/desktop/views/components/calendar.vue (100%) rename src/{ => server}/web/app/desktop/views/components/choose-file-from-drive-window.vue (100%) rename src/{ => server}/web/app/desktop/views/components/choose-folder-from-drive-window.vue (100%) rename src/{ => server}/web/app/desktop/views/components/context-menu.menu.vue (100%) rename src/{ => server}/web/app/desktop/views/components/context-menu.vue (100%) rename src/{ => server}/web/app/desktop/views/components/crop-window.vue (100%) rename src/{ => server}/web/app/desktop/views/components/dialog.vue (100%) rename src/{ => server}/web/app/desktop/views/components/drive-window.vue (100%) rename src/{ => server}/web/app/desktop/views/components/drive.file.vue (100%) rename src/{ => server}/web/app/desktop/views/components/drive.folder.vue (100%) rename src/{ => server}/web/app/desktop/views/components/drive.nav-folder.vue (100%) rename src/{ => server}/web/app/desktop/views/components/drive.vue (100%) rename src/{ => server}/web/app/desktop/views/components/ellipsis-icon.vue (100%) rename src/{ => server}/web/app/desktop/views/components/follow-button.vue (100%) rename src/{ => server}/web/app/desktop/views/components/followers-window.vue (100%) rename src/{ => server}/web/app/desktop/views/components/followers.vue (100%) rename src/{ => server}/web/app/desktop/views/components/following-window.vue (100%) rename src/{ => server}/web/app/desktop/views/components/following.vue (100%) rename src/{ => server}/web/app/desktop/views/components/friends-maker.vue (100%) rename src/{ => server}/web/app/desktop/views/components/game-window.vue (100%) rename src/{ => server}/web/app/desktop/views/components/home.vue (100%) rename src/{ => server}/web/app/desktop/views/components/index.ts (100%) rename src/{ => server}/web/app/desktop/views/components/input-dialog.vue (100%) rename src/{ => server}/web/app/desktop/views/components/media-image-dialog.vue (100%) rename src/{ => server}/web/app/desktop/views/components/media-image.vue (100%) rename src/{ => server}/web/app/desktop/views/components/media-video-dialog.vue (100%) rename src/{ => server}/web/app/desktop/views/components/media-video.vue (100%) rename src/{ => server}/web/app/desktop/views/components/mentions.vue (100%) rename src/{ => server}/web/app/desktop/views/components/messaging-room-window.vue (100%) rename src/{ => server}/web/app/desktop/views/components/messaging-window.vue (100%) rename src/{ => server}/web/app/desktop/views/components/notifications.vue (100%) rename src/{ => server}/web/app/desktop/views/components/post-detail.sub.vue (100%) rename src/{ => server}/web/app/desktop/views/components/post-detail.vue (100%) rename src/{ => server}/web/app/desktop/views/components/post-form-window.vue (100%) rename src/{ => server}/web/app/desktop/views/components/post-form.vue (100%) rename src/{ => server}/web/app/desktop/views/components/post-preview.vue (100%) rename src/{ => server}/web/app/desktop/views/components/posts.post.sub.vue (100%) rename src/{ => server}/web/app/desktop/views/components/posts.post.vue (100%) rename src/{ => server}/web/app/desktop/views/components/posts.vue (100%) rename src/{ => server}/web/app/desktop/views/components/progress-dialog.vue (100%) rename src/{ => server}/web/app/desktop/views/components/repost-form-window.vue (100%) rename src/{ => server}/web/app/desktop/views/components/repost-form.vue (100%) rename src/{ => server}/web/app/desktop/views/components/settings-window.vue (100%) rename src/{ => server}/web/app/desktop/views/components/settings.2fa.vue (100%) rename src/{ => server}/web/app/desktop/views/components/settings.api.vue (100%) rename src/{ => server}/web/app/desktop/views/components/settings.apps.vue (100%) rename src/{ => server}/web/app/desktop/views/components/settings.drive.vue (100%) rename src/{ => server}/web/app/desktop/views/components/settings.mute.vue (100%) rename src/{ => server}/web/app/desktop/views/components/settings.password.vue (100%) rename src/{ => server}/web/app/desktop/views/components/settings.profile.vue (100%) rename src/{ => server}/web/app/desktop/views/components/settings.signins.vue (100%) rename src/{ => server}/web/app/desktop/views/components/settings.vue (100%) rename src/{ => server}/web/app/desktop/views/components/sub-post-content.vue (100%) rename src/{ => server}/web/app/desktop/views/components/taskmanager.vue (100%) rename src/{ => server}/web/app/desktop/views/components/timeline.vue (100%) rename src/{ => server}/web/app/desktop/views/components/ui-notification.vue (100%) rename src/{ => server}/web/app/desktop/views/components/ui.header.account.vue (100%) rename src/{ => server}/web/app/desktop/views/components/ui.header.clock.vue (100%) rename src/{ => server}/web/app/desktop/views/components/ui.header.nav.vue (100%) rename src/{ => server}/web/app/desktop/views/components/ui.header.notifications.vue (100%) rename src/{ => server}/web/app/desktop/views/components/ui.header.post.vue (100%) rename src/{ => server}/web/app/desktop/views/components/ui.header.search.vue (100%) rename src/{ => server}/web/app/desktop/views/components/ui.header.vue (100%) rename src/{ => server}/web/app/desktop/views/components/ui.vue (100%) rename src/{ => server}/web/app/desktop/views/components/user-preview.vue (100%) rename src/{ => server}/web/app/desktop/views/components/users-list.item.vue (100%) rename src/{ => server}/web/app/desktop/views/components/users-list.vue (100%) rename src/{ => server}/web/app/desktop/views/components/widget-container.vue (100%) rename src/{ => server}/web/app/desktop/views/components/window.vue (100%) rename src/{ => server}/web/app/desktop/views/directives/index.ts (100%) rename src/{ => server}/web/app/desktop/views/directives/user-preview.ts (100%) rename src/{ => server}/web/app/desktop/views/pages/drive.vue (100%) rename src/{ => server}/web/app/desktop/views/pages/home-customize.vue (100%) rename src/{ => server}/web/app/desktop/views/pages/home.vue (100%) rename src/{ => server}/web/app/desktop/views/pages/index.vue (100%) rename src/{ => server}/web/app/desktop/views/pages/messaging-room.vue (100%) rename src/{ => server}/web/app/desktop/views/pages/othello.vue (100%) rename src/{ => server}/web/app/desktop/views/pages/post.vue (100%) rename src/{ => server}/web/app/desktop/views/pages/search.vue (100%) rename src/{ => server}/web/app/desktop/views/pages/selectdrive.vue (100%) rename src/{ => server}/web/app/desktop/views/pages/user/user.followers-you-know.vue (100%) rename src/{ => server}/web/app/desktop/views/pages/user/user.friends.vue (100%) rename src/{ => server}/web/app/desktop/views/pages/user/user.header.vue (100%) rename src/{ => server}/web/app/desktop/views/pages/user/user.home.vue (100%) rename src/{ => server}/web/app/desktop/views/pages/user/user.photos.vue (100%) rename src/{ => server}/web/app/desktop/views/pages/user/user.profile.vue (100%) rename src/{ => server}/web/app/desktop/views/pages/user/user.timeline.vue (100%) rename src/{ => server}/web/app/desktop/views/pages/user/user.vue (100%) rename src/{ => server}/web/app/desktop/views/pages/welcome.vue (100%) rename src/{ => server}/web/app/desktop/views/widgets/activity.vue (100%) rename src/{ => server}/web/app/desktop/views/widgets/channel.channel.form.vue (100%) rename src/{ => server}/web/app/desktop/views/widgets/channel.channel.post.vue (100%) rename src/{ => server}/web/app/desktop/views/widgets/channel.channel.vue (100%) rename src/{ => server}/web/app/desktop/views/widgets/channel.vue (100%) rename src/{ => server}/web/app/desktop/views/widgets/index.ts (100%) rename src/{ => server}/web/app/desktop/views/widgets/messaging.vue (100%) rename src/{ => server}/web/app/desktop/views/widgets/notifications.vue (100%) rename src/{ => server}/web/app/desktop/views/widgets/polls.vue (100%) rename src/{ => server}/web/app/desktop/views/widgets/post-form.vue (100%) rename src/{ => server}/web/app/desktop/views/widgets/profile.vue (100%) rename src/{ => server}/web/app/desktop/views/widgets/timemachine.vue (100%) rename src/{ => server}/web/app/desktop/views/widgets/trends.vue (100%) rename src/{ => server}/web/app/desktop/views/widgets/users.vue (100%) rename src/{ => server}/web/app/dev/script.ts (100%) rename src/{ => server}/web/app/dev/style.styl (100%) rename src/{ => server}/web/app/dev/views/app.vue (100%) rename src/{ => server}/web/app/dev/views/apps.vue (100%) rename src/{ => server}/web/app/dev/views/index.vue (100%) rename src/{ => server}/web/app/dev/views/new-app.vue (100%) rename src/{ => server}/web/app/dev/views/ui.vue (100%) rename src/{ => server}/web/app/init.css (100%) rename src/{ => server}/web/app/init.ts (100%) rename src/{ => server}/web/app/mobile/api/choose-drive-file.ts (100%) rename src/{ => server}/web/app/mobile/api/choose-drive-folder.ts (100%) rename src/{ => server}/web/app/mobile/api/dialog.ts (100%) rename src/{ => server}/web/app/mobile/api/input.ts (100%) rename src/{ => server}/web/app/mobile/api/notify.ts (100%) rename src/{ => server}/web/app/mobile/api/post.ts (100%) rename src/{ => server}/web/app/mobile/script.ts (100%) rename src/{ => server}/web/app/mobile/style.styl (100%) rename src/{ => server}/web/app/mobile/views/components/activity.vue (100%) rename src/{ => server}/web/app/mobile/views/components/drive-file-chooser.vue (100%) rename src/{ => server}/web/app/mobile/views/components/drive-folder-chooser.vue (100%) rename src/{ => server}/web/app/mobile/views/components/drive.file-detail.vue (100%) rename src/{ => server}/web/app/mobile/views/components/drive.file.vue (100%) rename src/{ => server}/web/app/mobile/views/components/drive.folder.vue (100%) rename src/{ => server}/web/app/mobile/views/components/drive.vue (100%) rename src/{ => server}/web/app/mobile/views/components/follow-button.vue (100%) rename src/{ => server}/web/app/mobile/views/components/friends-maker.vue (100%) rename src/{ => server}/web/app/mobile/views/components/index.ts (100%) rename src/{ => server}/web/app/mobile/views/components/media-image.vue (100%) rename src/{ => server}/web/app/mobile/views/components/media-video.vue (100%) rename src/{ => server}/web/app/mobile/views/components/notification-preview.vue (100%) rename src/{ => server}/web/app/mobile/views/components/notification.vue (100%) rename src/{ => server}/web/app/mobile/views/components/notifications.vue (100%) rename src/{ => server}/web/app/mobile/views/components/notify.vue (100%) rename src/{ => server}/web/app/mobile/views/components/post-card.vue (100%) rename src/{ => server}/web/app/mobile/views/components/post-detail.sub.vue (100%) rename src/{ => server}/web/app/mobile/views/components/post-detail.vue (100%) rename src/{ => server}/web/app/mobile/views/components/post-form.vue (100%) rename src/{ => server}/web/app/mobile/views/components/post-preview.vue (100%) rename src/{ => server}/web/app/mobile/views/components/post.sub.vue (100%) rename src/{ => server}/web/app/mobile/views/components/post.vue (100%) rename src/{ => server}/web/app/mobile/views/components/posts.vue (100%) rename src/{ => server}/web/app/mobile/views/components/sub-post-content.vue (100%) rename src/{ => server}/web/app/mobile/views/components/timeline.vue (100%) rename src/{ => server}/web/app/mobile/views/components/ui.header.vue (100%) rename src/{ => server}/web/app/mobile/views/components/ui.nav.vue (100%) rename src/{ => server}/web/app/mobile/views/components/ui.vue (100%) rename src/{ => server}/web/app/mobile/views/components/user-card.vue (100%) rename src/{ => server}/web/app/mobile/views/components/user-preview.vue (100%) rename src/{ => server}/web/app/mobile/views/components/user-timeline.vue (100%) rename src/{ => server}/web/app/mobile/views/components/users-list.vue (100%) rename src/{ => server}/web/app/mobile/views/components/widget-container.vue (100%) rename src/{ => server}/web/app/mobile/views/directives/index.ts (100%) rename src/{ => server}/web/app/mobile/views/directives/user-preview.ts (100%) rename src/{ => server}/web/app/mobile/views/pages/drive.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/followers.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/following.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/home.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/index.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/messaging-room.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/messaging.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/notifications.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/othello.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/post.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/profile-setting.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/search.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/selectdrive.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/settings.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/signup.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/user.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/user/home.followers-you-know.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/user/home.friends.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/user/home.photos.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/user/home.posts.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/user/home.vue (100%) rename src/{ => server}/web/app/mobile/views/pages/welcome.vue (100%) rename src/{ => server}/web/app/mobile/views/widgets/activity.vue (100%) rename src/{ => server}/web/app/mobile/views/widgets/index.ts (100%) rename src/{ => server}/web/app/mobile/views/widgets/profile.vue (100%) rename src/{ => server}/web/app/reset.styl (100%) rename src/{ => server}/web/app/safe.js (100%) rename src/{ => server}/web/app/stats/style.styl (100%) rename src/{ => server}/web/app/stats/tags/index.tag (100%) rename src/{ => server}/web/app/stats/tags/index.ts (100%) rename src/{ => server}/web/app/status/style.styl (100%) rename src/{ => server}/web/app/status/tags/index.tag (100%) rename src/{ => server}/web/app/status/tags/index.ts (100%) rename src/{ => server}/web/app/sw.js (100%) rename src/{ => server}/web/app/tsconfig.json (100%) rename src/{ => server}/web/app/v.d.ts (100%) rename src/{ => server}/web/assets/404.js (100%) rename src/{ => server}/web/assets/code-highlight.css (100%) rename src/{ => server}/web/assets/error.jpg (100%) rename src/{ => server}/web/assets/favicon.ico (100%) rename src/{ => server}/web/assets/label.svg (100%) rename src/{ => server}/web/assets/manifest.json (100%) rename src/{ => server}/web/assets/message.mp3 (100%) rename src/{ => server}/web/assets/othello-put-me.mp3 (100%) rename src/{ => server}/web/assets/othello-put-you.mp3 (100%) rename src/{ => server}/web/assets/post.mp3 (100%) rename src/{ => server}/web/assets/reactions/angry.png (100%) rename src/{ => server}/web/assets/reactions/confused.png (100%) rename src/{ => server}/web/assets/reactions/congrats.png (100%) rename src/{ => server}/web/assets/reactions/hmm.png (100%) rename src/{ => server}/web/assets/reactions/laugh.png (100%) rename src/{ => server}/web/assets/reactions/like.png (100%) rename src/{ => server}/web/assets/reactions/love.png (100%) rename src/{ => server}/web/assets/reactions/pudding.png (100%) rename src/{ => server}/web/assets/reactions/surprise.png (100%) rename src/{ => server}/web/assets/recover.html (100%) rename src/{ => server}/web/assets/title.svg (100%) rename src/{ => server}/web/assets/unread.svg (100%) rename src/{ => server}/web/assets/welcome-bg.svg (100%) rename src/{ => server}/web/assets/welcome-fg.svg (100%) rename src/{ => server}/web/const.styl (74%) rename src/{ => server}/web/docs/about.en.pug (100%) rename src/{ => server}/web/docs/about.ja.pug (100%) rename src/{ => server}/web/docs/api.ja.pug (100%) rename src/{ => server}/web/docs/api/endpoints/posts/create.yaml (100%) rename src/{ => server}/web/docs/api/endpoints/posts/timeline.yaml (100%) rename src/{ => server}/web/docs/api/endpoints/style.styl (100%) rename src/{ => server}/web/docs/api/endpoints/view.pug (100%) rename src/{ => server}/web/docs/api/entities/drive-file.yaml (100%) rename src/{ => server}/web/docs/api/entities/post.yaml (100%) rename src/{ => server}/web/docs/api/entities/style.styl (100%) rename src/{ => server}/web/docs/api/entities/user.yaml (100%) rename src/{ => server}/web/docs/api/entities/view.pug (100%) rename src/{ => server}/web/docs/api/gulpfile.ts (80%) rename src/{ => server}/web/docs/api/mixins.pug (100%) rename src/{ => server}/web/docs/api/style.styl (100%) rename src/{ => server}/web/docs/gulpfile.ts (74%) rename src/{ => server}/web/docs/index.en.pug (100%) rename src/{ => server}/web/docs/index.ja.pug (100%) rename src/{ => server}/web/docs/layout.pug (100%) rename src/{ => server}/web/docs/license.en.pug (100%) rename src/{ => server}/web/docs/license.ja.pug (100%) rename src/{ => server}/web/docs/mute.ja.pug (100%) rename src/{ => server}/web/docs/search.ja.pug (100%) rename src/{ => server}/web/docs/server.ts (100%) rename src/{ => server}/web/docs/style.styl (100%) rename src/{ => server}/web/docs/tou.ja.pug (100%) rename src/{ => server}/web/docs/ui.styl (100%) rename src/{ => server}/web/docs/vars.ts (76%) rename src/{ => server}/web/element.scss (91%) rename src/{ => server}/web/server.ts (100%) rename src/{ => server}/web/service/url-preview.ts (100%) rename src/{ => server}/web/style.styl (100%) diff --git a/gulpfile.ts b/gulpfile.ts index 9c61e3a1c..11f34c962 100644 --- a/gulpfile.ts +++ b/gulpfile.ts @@ -22,7 +22,7 @@ import * as replace from 'gulp-replace'; import * as htmlmin from 'gulp-htmlmin'; const uglifyes = require('uglify-es'); -import { fa } from './src/common/build/fa'; +import { fa } from './src/build/fa'; import version from './src/version'; import config from './src/conf'; @@ -39,7 +39,7 @@ if (isDebug) { const constants = require('./src/const.json'); -require('./src/web/docs/gulpfile.ts'); +require('./src/server/web/docs/gulpfile.ts'); gulp.task('build', [ 'build:js', @@ -52,7 +52,7 @@ gulp.task('build', [ gulp.task('rebuild', ['clean', 'build']); gulp.task('build:js', () => - gulp.src(['./src/**/*.js', '!./src/web/**/*.js']) + gulp.src(['./src/**/*.js', '!./src/server/web/**/*.js']) .pipe(gulp.dest('./built/')) ); @@ -71,7 +71,7 @@ gulp.task('build:copy', () => gulp.src([ './build/Release/crypto_key.node', './src/**/assets/**/*', - '!./src/web/app/**/assets/**/*' + '!./src/server/web/app/**/assets/**/*' ]).pipe(gulp.dest('./built/')) ); @@ -121,7 +121,7 @@ gulp.task('build:client', [ ]); gulp.task('build:client:script', () => - gulp.src(['./src/web/app/boot.js', './src/web/app/safe.js']) + gulp.src(['./src/server/web/app/boot.js', './src/server/web/app/safe.js']) .pipe(replace('VERSION', JSON.stringify(version))) .pipe(replace('API', JSON.stringify(config.api_url))) .pipe(replace('ENV', JSON.stringify(env))) @@ -129,15 +129,15 @@ gulp.task('build:client:script', () => .pipe(isProduction ? uglify({ toplevel: true } as any) : gutil.noop()) - .pipe(gulp.dest('./built/web/assets/')) as any + .pipe(gulp.dest('./built/server/web/assets/')) as any ); gulp.task('build:client:styles', () => - gulp.src('./src/web/app/init.css') + gulp.src('./src/server/web/app/init.css') .pipe(isProduction ? (cssnano as any)() : gutil.noop()) - .pipe(gulp.dest('./built/web/assets/')) + .pipe(gulp.dest('./built/server/web/assets/')) ); gulp.task('copy:client', [ @@ -145,14 +145,14 @@ gulp.task('copy:client', [ ], () => gulp.src([ './assets/**/*', - './src/web/assets/**/*', - './src/web/app/*/assets/**/*' + './src/server/web/assets/**/*', + './src/server/web/app/*/assets/**/*' ]) .pipe(isProduction ? (imagemin as any)() : gutil.noop()) .pipe(rename(path => { path.dirname = path.dirname.replace('assets', '.'); })) - .pipe(gulp.dest('./built/web/assets/')) + .pipe(gulp.dest('./built/server/web/assets/')) ); gulp.task('build:client:pug', [ @@ -160,13 +160,13 @@ gulp.task('build:client:pug', [ 'build:client:script', 'build:client:styles' ], () => - gulp.src('./src/web/app/base.pug') + gulp.src('./src/server/web/app/base.pug') .pipe(pug({ locals: { themeColor: constants.themeColor, facss: fa.dom.css(), //hljscss: fs.readFileSync('./node_modules/highlight.js/styles/default.css', 'utf8') - hljscss: fs.readFileSync('./src/web/assets/code-highlight.css', 'utf8') + hljscss: fs.readFileSync('./src/server/web/assets/code-highlight.css', 'utf8') } })) .pipe(htmlmin({ @@ -201,5 +201,5 @@ gulp.task('build:client:pug', [ // CSSも圧縮する minifyCSS: true })) - .pipe(gulp.dest('./built/web/app/')) + .pipe(gulp.dest('./built/server/web/app/')) ); diff --git a/package.json b/package.json index d9ed80b47..290fb00d7 100644 --- a/package.json +++ b/package.json @@ -135,6 +135,7 @@ "is-url": "1.2.3", "js-yaml": "3.11.0", "jsdom": "^11.6.2", + "kue": "^0.11.6", "license-checker": "18.0.0", "loader-utils": "1.1.0", "mecab-async": "0.1.2", @@ -149,6 +150,7 @@ "nan": "^2.10.0", "node-sass": "4.7.2", "node-sass-json-importer": "3.1.5", + "nopt": "^4.0.1", "nprogress": "0.2.0", "object-assign-deep": "0.3.1", "on-build-webpack": "0.1.0", diff --git a/src/common/build/fa.ts b/src/build/fa.ts similarity index 100% rename from src/common/build/fa.ts rename to src/build/fa.ts diff --git a/src/common/build/i18n.ts b/src/build/i18n.ts similarity index 96% rename from src/common/build/i18n.ts rename to src/build/i18n.ts index 5e3c0381a..b9b740321 100644 --- a/src/common/build/i18n.ts +++ b/src/build/i18n.ts @@ -2,7 +2,7 @@ * Replace i18n texts */ -import locale from '../../../locales'; +import locale from '../../locales'; export default class Replacer { private lang: string; diff --git a/src/common/build/license.ts b/src/build/license.ts similarity index 72% rename from src/common/build/license.ts rename to src/build/license.ts index e5c264df8..d36af665c 100644 --- a/src/common/build/license.ts +++ b/src/build/license.ts @@ -1,6 +1,6 @@ import * as fs from 'fs'; -const license = fs.readFileSync(__dirname + '/../../../LICENSE', 'utf-8'); +const license = fs.readFileSync(__dirname + '/../../LICENSE', 'utf-8'); const licenseHtml = license .replace(/\r\n/g, '\n') diff --git a/src/index.ts b/src/index.ts index 218455d6f..bd9b094d9 100644 --- a/src/index.ts +++ b/src/index.ts @@ -24,6 +24,8 @@ import stats from './utils/stats'; import { Config, path as configPath } from './config'; import loadConfig from './config'; +import parseOpt from './parse-opt'; + const clusterLog = debug('misskey:cluster'); const ev = new Xev(); @@ -36,20 +38,22 @@ main(); * Init process */ function main() { + const opt = parseOpt(process.argv, 2); + if (cluster.isMaster) { - masterMain(); + masterMain(opt); ev.mount(); stats(); } else { - workerMain(); + workerMain(opt); } } /** * Init master process */ -async function masterMain() { +async function masterMain(opt) { let config: Config; try { @@ -69,19 +73,35 @@ async function masterMain() { } spawnWorkers(() => { - Logger.info(chalk.bold.green( - `Now listening on port ${chalk.underline(config.port.toString())}`)); + if (!opt['only-processor']) { + Logger.info(chalk.bold.green( + `Now listening on port ${chalk.underline(config.port.toString())}`)); - Logger.info(chalk.bold.green(config.url)); + Logger.info(chalk.bold.green(config.url)); + } + + if (!opt['only-server']) { + Logger.info(chalk.bold.green('Now processing jobs')); + } }); } /** * Init worker process */ -function workerMain() { - // start server - require('./server'); +async function workerMain(opt) { + if (!opt['only-processor']) { + // start server + await require('./server').default(); + } + + if (!opt['only-server']) { + // start processor + require('./processor').default(); + } + + // Send a 'ready' message to parent process + process.send('ready'); } /** diff --git a/src/parse-opt.ts b/src/parse-opt.ts new file mode 100644 index 000000000..61dc60c6c --- /dev/null +++ b/src/parse-opt.ts @@ -0,0 +1,17 @@ +const nopt = require('nopt'); + +export default (vector, index) => { + const parsed = nopt({ + 'only-processor': Boolean, + 'only-server': Boolean + }, { + p: ['--only-processor'], + s: ['--only-server'] + }, vector, index); + + if (parsed['only-processor'] && parsed['only-server']) { + throw 'only-processor option and only-server option cannot be set at the same time'; + } + + return parsed; +}; diff --git a/src/processor/index.ts b/src/processor/index.ts new file mode 100644 index 000000000..f06cf24e8 --- /dev/null +++ b/src/processor/index.ts @@ -0,0 +1,4 @@ +import queue from '../queue'; +import reportGitHubFailure from './report-github-failure'; + +export default () => queue.process('gitHubFailureReport', reportGitHubFailure); diff --git a/src/processor/report-github-failure.ts b/src/processor/report-github-failure.ts new file mode 100644 index 000000000..f42071142 --- /dev/null +++ b/src/processor/report-github-failure.ts @@ -0,0 +1,29 @@ +import * as request from 'request'; +import User from '../server/api/models/user'; +const createPost = require('../server/api/endpoints/posts/create'); + +export default ({ data }, done) => { + const asyncBot = User.findOne({ _id: data.userId }); + + // Fetch parent status + request({ + url: `${data.parentUrl}/statuses`, + headers: { + 'User-Agent': 'misskey' + } + }, async (err, res, body) => { + if (err) { + console.error(err); + return; + } + const parentStatuses = JSON.parse(body); + const parentState = parentStatuses[0].state; + const stillFailed = parentState == 'failure' || parentState == 'error'; + const text = stillFailed ? + `**⚠️BUILD STILL FAILED⚠️**: ?[${data.message}](${data.htmlUrl})` : + `**🚨BUILD FAILED🚨**: →→→?[${data.message}](${data.htmlUrl})←←←`; + + createPost({ text }, await asyncBot); + done(); + }); +}; diff --git a/src/queue.ts b/src/queue.ts new file mode 100644 index 000000000..6089e0a7f --- /dev/null +++ b/src/queue.ts @@ -0,0 +1,10 @@ +import { createQueue } from 'kue'; +import config from './conf'; + +export default createQueue({ + redis: { + port: config.redis.port, + host: config.redis.host, + auth: config.redis.pass + } +}); diff --git a/src/api/api-handler.ts b/src/server/api/api-handler.ts similarity index 100% rename from src/api/api-handler.ts rename to src/server/api/api-handler.ts diff --git a/src/api/authenticate.ts b/src/server/api/authenticate.ts similarity index 100% rename from src/api/authenticate.ts rename to src/server/api/authenticate.ts diff --git a/src/api/bot/core.ts b/src/server/api/bot/core.ts similarity index 100% rename from src/api/bot/core.ts rename to src/server/api/bot/core.ts diff --git a/src/api/bot/interfaces/line.ts b/src/server/api/bot/interfaces/line.ts similarity index 98% rename from src/api/bot/interfaces/line.ts rename to src/server/api/bot/interfaces/line.ts index 8036b2fde..5b3e9107f 100644 --- a/src/api/bot/interfaces/line.ts +++ b/src/server/api/bot/interfaces/line.ts @@ -3,9 +3,9 @@ import * as express from 'express'; import * as request from 'request'; import * as crypto from 'crypto'; import User from '../../models/user'; -import config from '../../../conf'; +import config from '../../../../conf'; import BotCore from '../core'; -import _redis from '../../../db/redis'; +import _redis from '../../../../db/redis'; import prominence = require('prominence'); import getAcct from '../../../common/user/get-acct'; import parseAcct from '../../../common/user/parse-acct'; diff --git a/src/api/common/drive/add-file.ts b/src/server/api/common/drive/add-file.ts similarity index 99% rename from src/api/common/drive/add-file.ts rename to src/server/api/common/drive/add-file.ts index c4f2f212a..5f3c69c15 100644 --- a/src/api/common/drive/add-file.ts +++ b/src/server/api/common/drive/add-file.ts @@ -15,7 +15,7 @@ import DriveFolder from '../../models/drive-folder'; import { pack } from '../../models/drive-file'; import event, { publishDriveStream } from '../../event'; import getAcct from '../../../common/user/get-acct'; -import config from '../../../conf'; +import config from '../../../../conf'; const gm = _gm.subClass({ imageMagick: true diff --git a/src/api/common/drive/upload_from_url.ts b/src/server/api/common/drive/upload_from_url.ts similarity index 100% rename from src/api/common/drive/upload_from_url.ts rename to src/server/api/common/drive/upload_from_url.ts diff --git a/src/api/common/generate-native-user-token.ts b/src/server/api/common/generate-native-user-token.ts similarity index 100% rename from src/api/common/generate-native-user-token.ts rename to src/server/api/common/generate-native-user-token.ts diff --git a/src/api/common/get-friends.ts b/src/server/api/common/get-friends.ts similarity index 100% rename from src/api/common/get-friends.ts rename to src/server/api/common/get-friends.ts diff --git a/src/api/common/get-host-lower.ts b/src/server/api/common/get-host-lower.ts similarity index 100% rename from src/api/common/get-host-lower.ts rename to src/server/api/common/get-host-lower.ts diff --git a/src/api/common/is-native-token.ts b/src/server/api/common/is-native-token.ts similarity index 100% rename from src/api/common/is-native-token.ts rename to src/server/api/common/is-native-token.ts diff --git a/src/api/common/notify.ts b/src/server/api/common/notify.ts similarity index 100% rename from src/api/common/notify.ts rename to src/server/api/common/notify.ts diff --git a/src/api/common/push-sw.ts b/src/server/api/common/push-sw.ts similarity index 97% rename from src/api/common/push-sw.ts rename to src/server/api/common/push-sw.ts index 2993c760e..b33715eb1 100644 --- a/src/api/common/push-sw.ts +++ b/src/server/api/common/push-sw.ts @@ -1,7 +1,7 @@ const push = require('web-push'); import * as mongo from 'mongodb'; import Subscription from '../models/sw-subscription'; -import config from '../../conf'; +import config from '../../../conf'; if (config.sw) { // アプリケーションの連絡先と、サーバーサイドの鍵ペアの情報を登録 diff --git a/src/api/common/read-messaging-message.ts b/src/server/api/common/read-messaging-message.ts similarity index 100% rename from src/api/common/read-messaging-message.ts rename to src/server/api/common/read-messaging-message.ts diff --git a/src/api/common/read-notification.ts b/src/server/api/common/read-notification.ts similarity index 100% rename from src/api/common/read-notification.ts rename to src/server/api/common/read-notification.ts diff --git a/src/api/common/signin.ts b/src/server/api/common/signin.ts similarity index 92% rename from src/api/common/signin.ts rename to src/server/api/common/signin.ts index 04c2cdac8..a11ea56c0 100644 --- a/src/api/common/signin.ts +++ b/src/server/api/common/signin.ts @@ -1,4 +1,4 @@ -import config from '../../conf'; +import config from '../../../conf'; export default function(res, user, redirect: boolean) { const expires = 1000 * 60 * 60 * 24 * 365; // One Year diff --git a/src/api/common/text/core/syntax-highlighter.ts b/src/server/api/common/text/core/syntax-highlighter.ts similarity index 100% rename from src/api/common/text/core/syntax-highlighter.ts rename to src/server/api/common/text/core/syntax-highlighter.ts diff --git a/src/api/common/text/elements/bold.ts b/src/server/api/common/text/elements/bold.ts similarity index 100% rename from src/api/common/text/elements/bold.ts rename to src/server/api/common/text/elements/bold.ts diff --git a/src/api/common/text/elements/code.ts b/src/server/api/common/text/elements/code.ts similarity index 100% rename from src/api/common/text/elements/code.ts rename to src/server/api/common/text/elements/code.ts diff --git a/src/api/common/text/elements/emoji.ts b/src/server/api/common/text/elements/emoji.ts similarity index 100% rename from src/api/common/text/elements/emoji.ts rename to src/server/api/common/text/elements/emoji.ts diff --git a/src/api/common/text/elements/hashtag.ts b/src/server/api/common/text/elements/hashtag.ts similarity index 100% rename from src/api/common/text/elements/hashtag.ts rename to src/server/api/common/text/elements/hashtag.ts diff --git a/src/api/common/text/elements/inline-code.ts b/src/server/api/common/text/elements/inline-code.ts similarity index 100% rename from src/api/common/text/elements/inline-code.ts rename to src/server/api/common/text/elements/inline-code.ts diff --git a/src/api/common/text/elements/link.ts b/src/server/api/common/text/elements/link.ts similarity index 100% rename from src/api/common/text/elements/link.ts rename to src/server/api/common/text/elements/link.ts diff --git a/src/api/common/text/elements/mention.ts b/src/server/api/common/text/elements/mention.ts similarity index 100% rename from src/api/common/text/elements/mention.ts rename to src/server/api/common/text/elements/mention.ts diff --git a/src/api/common/text/elements/quote.ts b/src/server/api/common/text/elements/quote.ts similarity index 100% rename from src/api/common/text/elements/quote.ts rename to src/server/api/common/text/elements/quote.ts diff --git a/src/api/common/text/elements/url.ts b/src/server/api/common/text/elements/url.ts similarity index 100% rename from src/api/common/text/elements/url.ts rename to src/server/api/common/text/elements/url.ts diff --git a/src/api/common/text/index.ts b/src/server/api/common/text/index.ts similarity index 100% rename from src/api/common/text/index.ts rename to src/server/api/common/text/index.ts diff --git a/src/api/common/watch-post.ts b/src/server/api/common/watch-post.ts similarity index 100% rename from src/api/common/watch-post.ts rename to src/server/api/common/watch-post.ts diff --git a/src/api/endpoints.ts b/src/server/api/endpoints.ts similarity index 100% rename from src/api/endpoints.ts rename to src/server/api/endpoints.ts diff --git a/src/api/endpoints/aggregation/posts.ts b/src/server/api/endpoints/aggregation/posts.ts similarity index 100% rename from src/api/endpoints/aggregation/posts.ts rename to src/server/api/endpoints/aggregation/posts.ts diff --git a/src/api/endpoints/aggregation/posts/reaction.ts b/src/server/api/endpoints/aggregation/posts/reaction.ts similarity index 100% rename from src/api/endpoints/aggregation/posts/reaction.ts rename to src/server/api/endpoints/aggregation/posts/reaction.ts diff --git a/src/api/endpoints/aggregation/posts/reactions.ts b/src/server/api/endpoints/aggregation/posts/reactions.ts similarity index 100% rename from src/api/endpoints/aggregation/posts/reactions.ts rename to src/server/api/endpoints/aggregation/posts/reactions.ts diff --git a/src/api/endpoints/aggregation/posts/reply.ts b/src/server/api/endpoints/aggregation/posts/reply.ts similarity index 100% rename from src/api/endpoints/aggregation/posts/reply.ts rename to src/server/api/endpoints/aggregation/posts/reply.ts diff --git a/src/api/endpoints/aggregation/posts/repost.ts b/src/server/api/endpoints/aggregation/posts/repost.ts similarity index 100% rename from src/api/endpoints/aggregation/posts/repost.ts rename to src/server/api/endpoints/aggregation/posts/repost.ts diff --git a/src/api/endpoints/aggregation/users.ts b/src/server/api/endpoints/aggregation/users.ts similarity index 100% rename from src/api/endpoints/aggregation/users.ts rename to src/server/api/endpoints/aggregation/users.ts diff --git a/src/api/endpoints/aggregation/users/activity.ts b/src/server/api/endpoints/aggregation/users/activity.ts similarity index 100% rename from src/api/endpoints/aggregation/users/activity.ts rename to src/server/api/endpoints/aggregation/users/activity.ts diff --git a/src/api/endpoints/aggregation/users/followers.ts b/src/server/api/endpoints/aggregation/users/followers.ts similarity index 100% rename from src/api/endpoints/aggregation/users/followers.ts rename to src/server/api/endpoints/aggregation/users/followers.ts diff --git a/src/api/endpoints/aggregation/users/following.ts b/src/server/api/endpoints/aggregation/users/following.ts similarity index 100% rename from src/api/endpoints/aggregation/users/following.ts rename to src/server/api/endpoints/aggregation/users/following.ts diff --git a/src/api/endpoints/aggregation/users/post.ts b/src/server/api/endpoints/aggregation/users/post.ts similarity index 100% rename from src/api/endpoints/aggregation/users/post.ts rename to src/server/api/endpoints/aggregation/users/post.ts diff --git a/src/api/endpoints/aggregation/users/reaction.ts b/src/server/api/endpoints/aggregation/users/reaction.ts similarity index 100% rename from src/api/endpoints/aggregation/users/reaction.ts rename to src/server/api/endpoints/aggregation/users/reaction.ts diff --git a/src/api/endpoints/app/create.ts b/src/server/api/endpoints/app/create.ts similarity index 100% rename from src/api/endpoints/app/create.ts rename to src/server/api/endpoints/app/create.ts diff --git a/src/api/endpoints/app/name_id/available.ts b/src/server/api/endpoints/app/name_id/available.ts similarity index 100% rename from src/api/endpoints/app/name_id/available.ts rename to src/server/api/endpoints/app/name_id/available.ts diff --git a/src/api/endpoints/app/show.ts b/src/server/api/endpoints/app/show.ts similarity index 100% rename from src/api/endpoints/app/show.ts rename to src/server/api/endpoints/app/show.ts diff --git a/src/api/endpoints/auth/accept.ts b/src/server/api/endpoints/auth/accept.ts similarity index 100% rename from src/api/endpoints/auth/accept.ts rename to src/server/api/endpoints/auth/accept.ts diff --git a/src/api/endpoints/auth/session/generate.ts b/src/server/api/endpoints/auth/session/generate.ts similarity index 97% rename from src/api/endpoints/auth/session/generate.ts rename to src/server/api/endpoints/auth/session/generate.ts index 510382247..dc6a045b6 100644 --- a/src/api/endpoints/auth/session/generate.ts +++ b/src/server/api/endpoints/auth/session/generate.ts @@ -5,7 +5,7 @@ import * as uuid from 'uuid'; import $ from 'cafy'; import App from '../../../models/app'; import AuthSess from '../../../models/auth-session'; -import config from '../../../../conf'; +import config from '../../../../../conf'; /** * @swagger diff --git a/src/api/endpoints/auth/session/show.ts b/src/server/api/endpoints/auth/session/show.ts similarity index 100% rename from src/api/endpoints/auth/session/show.ts rename to src/server/api/endpoints/auth/session/show.ts diff --git a/src/api/endpoints/auth/session/userkey.ts b/src/server/api/endpoints/auth/session/userkey.ts similarity index 100% rename from src/api/endpoints/auth/session/userkey.ts rename to src/server/api/endpoints/auth/session/userkey.ts diff --git a/src/api/endpoints/channels.ts b/src/server/api/endpoints/channels.ts similarity index 100% rename from src/api/endpoints/channels.ts rename to src/server/api/endpoints/channels.ts diff --git a/src/api/endpoints/channels/create.ts b/src/server/api/endpoints/channels/create.ts similarity index 100% rename from src/api/endpoints/channels/create.ts rename to src/server/api/endpoints/channels/create.ts diff --git a/src/api/endpoints/channels/posts.ts b/src/server/api/endpoints/channels/posts.ts similarity index 100% rename from src/api/endpoints/channels/posts.ts rename to src/server/api/endpoints/channels/posts.ts diff --git a/src/api/endpoints/channels/show.ts b/src/server/api/endpoints/channels/show.ts similarity index 100% rename from src/api/endpoints/channels/show.ts rename to src/server/api/endpoints/channels/show.ts diff --git a/src/api/endpoints/channels/unwatch.ts b/src/server/api/endpoints/channels/unwatch.ts similarity index 100% rename from src/api/endpoints/channels/unwatch.ts rename to src/server/api/endpoints/channels/unwatch.ts diff --git a/src/api/endpoints/channels/watch.ts b/src/server/api/endpoints/channels/watch.ts similarity index 100% rename from src/api/endpoints/channels/watch.ts rename to src/server/api/endpoints/channels/watch.ts diff --git a/src/api/endpoints/drive.ts b/src/server/api/endpoints/drive.ts similarity index 100% rename from src/api/endpoints/drive.ts rename to src/server/api/endpoints/drive.ts diff --git a/src/api/endpoints/drive/files.ts b/src/server/api/endpoints/drive/files.ts similarity index 100% rename from src/api/endpoints/drive/files.ts rename to src/server/api/endpoints/drive/files.ts diff --git a/src/api/endpoints/drive/files/create.ts b/src/server/api/endpoints/drive/files/create.ts similarity index 100% rename from src/api/endpoints/drive/files/create.ts rename to src/server/api/endpoints/drive/files/create.ts diff --git a/src/api/endpoints/drive/files/find.ts b/src/server/api/endpoints/drive/files/find.ts similarity index 100% rename from src/api/endpoints/drive/files/find.ts rename to src/server/api/endpoints/drive/files/find.ts diff --git a/src/api/endpoints/drive/files/show.ts b/src/server/api/endpoints/drive/files/show.ts similarity index 100% rename from src/api/endpoints/drive/files/show.ts rename to src/server/api/endpoints/drive/files/show.ts diff --git a/src/api/endpoints/drive/files/update.ts b/src/server/api/endpoints/drive/files/update.ts similarity index 100% rename from src/api/endpoints/drive/files/update.ts rename to src/server/api/endpoints/drive/files/update.ts diff --git a/src/api/endpoints/drive/files/upload_from_url.ts b/src/server/api/endpoints/drive/files/upload_from_url.ts similarity index 100% rename from src/api/endpoints/drive/files/upload_from_url.ts rename to src/server/api/endpoints/drive/files/upload_from_url.ts diff --git a/src/api/endpoints/drive/folders.ts b/src/server/api/endpoints/drive/folders.ts similarity index 100% rename from src/api/endpoints/drive/folders.ts rename to src/server/api/endpoints/drive/folders.ts diff --git a/src/api/endpoints/drive/folders/create.ts b/src/server/api/endpoints/drive/folders/create.ts similarity index 100% rename from src/api/endpoints/drive/folders/create.ts rename to src/server/api/endpoints/drive/folders/create.ts diff --git a/src/api/endpoints/drive/folders/find.ts b/src/server/api/endpoints/drive/folders/find.ts similarity index 100% rename from src/api/endpoints/drive/folders/find.ts rename to src/server/api/endpoints/drive/folders/find.ts diff --git a/src/api/endpoints/drive/folders/show.ts b/src/server/api/endpoints/drive/folders/show.ts similarity index 100% rename from src/api/endpoints/drive/folders/show.ts rename to src/server/api/endpoints/drive/folders/show.ts diff --git a/src/api/endpoints/drive/folders/update.ts b/src/server/api/endpoints/drive/folders/update.ts similarity index 100% rename from src/api/endpoints/drive/folders/update.ts rename to src/server/api/endpoints/drive/folders/update.ts diff --git a/src/api/endpoints/drive/stream.ts b/src/server/api/endpoints/drive/stream.ts similarity index 100% rename from src/api/endpoints/drive/stream.ts rename to src/server/api/endpoints/drive/stream.ts diff --git a/src/api/endpoints/following/create.ts b/src/server/api/endpoints/following/create.ts similarity index 100% rename from src/api/endpoints/following/create.ts rename to src/server/api/endpoints/following/create.ts diff --git a/src/api/endpoints/following/delete.ts b/src/server/api/endpoints/following/delete.ts similarity index 100% rename from src/api/endpoints/following/delete.ts rename to src/server/api/endpoints/following/delete.ts diff --git a/src/api/endpoints/i.ts b/src/server/api/endpoints/i.ts similarity index 100% rename from src/api/endpoints/i.ts rename to src/server/api/endpoints/i.ts diff --git a/src/api/endpoints/i/2fa/done.ts b/src/server/api/endpoints/i/2fa/done.ts similarity index 100% rename from src/api/endpoints/i/2fa/done.ts rename to src/server/api/endpoints/i/2fa/done.ts diff --git a/src/api/endpoints/i/2fa/register.ts b/src/server/api/endpoints/i/2fa/register.ts similarity index 96% rename from src/api/endpoints/i/2fa/register.ts rename to src/server/api/endpoints/i/2fa/register.ts index 24abfcdfc..e2cc1487b 100644 --- a/src/api/endpoints/i/2fa/register.ts +++ b/src/server/api/endpoints/i/2fa/register.ts @@ -6,7 +6,7 @@ import * as bcrypt from 'bcryptjs'; import * as speakeasy from 'speakeasy'; import * as QRCode from 'qrcode'; import User from '../../../models/user'; -import config from '../../../../conf'; +import config from '../../../../../conf'; module.exports = async (params, user) => new Promise(async (res, rej) => { // Get 'password' parameter diff --git a/src/api/endpoints/i/2fa/unregister.ts b/src/server/api/endpoints/i/2fa/unregister.ts similarity index 100% rename from src/api/endpoints/i/2fa/unregister.ts rename to src/server/api/endpoints/i/2fa/unregister.ts diff --git a/src/api/endpoints/i/appdata/get.ts b/src/server/api/endpoints/i/appdata/get.ts similarity index 100% rename from src/api/endpoints/i/appdata/get.ts rename to src/server/api/endpoints/i/appdata/get.ts diff --git a/src/api/endpoints/i/appdata/set.ts b/src/server/api/endpoints/i/appdata/set.ts similarity index 100% rename from src/api/endpoints/i/appdata/set.ts rename to src/server/api/endpoints/i/appdata/set.ts diff --git a/src/api/endpoints/i/authorized_apps.ts b/src/server/api/endpoints/i/authorized_apps.ts similarity index 100% rename from src/api/endpoints/i/authorized_apps.ts rename to src/server/api/endpoints/i/authorized_apps.ts diff --git a/src/api/endpoints/i/change_password.ts b/src/server/api/endpoints/i/change_password.ts similarity index 100% rename from src/api/endpoints/i/change_password.ts rename to src/server/api/endpoints/i/change_password.ts diff --git a/src/api/endpoints/i/favorites.ts b/src/server/api/endpoints/i/favorites.ts similarity index 100% rename from src/api/endpoints/i/favorites.ts rename to src/server/api/endpoints/i/favorites.ts diff --git a/src/api/endpoints/i/notifications.ts b/src/server/api/endpoints/i/notifications.ts similarity index 100% rename from src/api/endpoints/i/notifications.ts rename to src/server/api/endpoints/i/notifications.ts diff --git a/src/api/endpoints/i/pin.ts b/src/server/api/endpoints/i/pin.ts similarity index 100% rename from src/api/endpoints/i/pin.ts rename to src/server/api/endpoints/i/pin.ts diff --git a/src/api/endpoints/i/regenerate_token.ts b/src/server/api/endpoints/i/regenerate_token.ts similarity index 100% rename from src/api/endpoints/i/regenerate_token.ts rename to src/server/api/endpoints/i/regenerate_token.ts diff --git a/src/api/endpoints/i/signin_history.ts b/src/server/api/endpoints/i/signin_history.ts similarity index 100% rename from src/api/endpoints/i/signin_history.ts rename to src/server/api/endpoints/i/signin_history.ts diff --git a/src/api/endpoints/i/update.ts b/src/server/api/endpoints/i/update.ts similarity index 98% rename from src/api/endpoints/i/update.ts rename to src/server/api/endpoints/i/update.ts index db8a3f25b..3d52de2cc 100644 --- a/src/api/endpoints/i/update.ts +++ b/src/server/api/endpoints/i/update.ts @@ -4,7 +4,7 @@ import $ from 'cafy'; import User, { isValidName, isValidDescription, isValidLocation, isValidBirthday, pack } from '../../models/user'; import event from '../../event'; -import config from '../../../conf'; +import config from '../../../../conf'; /** * Update myself diff --git a/src/api/endpoints/i/update_client_setting.ts b/src/server/api/endpoints/i/update_client_setting.ts similarity index 100% rename from src/api/endpoints/i/update_client_setting.ts rename to src/server/api/endpoints/i/update_client_setting.ts diff --git a/src/api/endpoints/i/update_home.ts b/src/server/api/endpoints/i/update_home.ts similarity index 100% rename from src/api/endpoints/i/update_home.ts rename to src/server/api/endpoints/i/update_home.ts diff --git a/src/api/endpoints/i/update_mobile_home.ts b/src/server/api/endpoints/i/update_mobile_home.ts similarity index 100% rename from src/api/endpoints/i/update_mobile_home.ts rename to src/server/api/endpoints/i/update_mobile_home.ts diff --git a/src/api/endpoints/messaging/history.ts b/src/server/api/endpoints/messaging/history.ts similarity index 100% rename from src/api/endpoints/messaging/history.ts rename to src/server/api/endpoints/messaging/history.ts diff --git a/src/api/endpoints/messaging/messages.ts b/src/server/api/endpoints/messaging/messages.ts similarity index 100% rename from src/api/endpoints/messaging/messages.ts rename to src/server/api/endpoints/messaging/messages.ts diff --git a/src/api/endpoints/messaging/messages/create.ts b/src/server/api/endpoints/messaging/messages/create.ts similarity index 99% rename from src/api/endpoints/messaging/messages/create.ts rename to src/server/api/endpoints/messaging/messages/create.ts index 1b8a5f59e..5184b2bd3 100644 --- a/src/api/endpoints/messaging/messages/create.ts +++ b/src/server/api/endpoints/messaging/messages/create.ts @@ -11,7 +11,7 @@ import DriveFile from '../../../models/drive-file'; import { pack } from '../../../models/messaging-message'; import publishUserStream from '../../../event'; import { publishMessagingStream, publishMessagingIndexStream, pushSw } from '../../../event'; -import config from '../../../../conf'; +import config from '../../../../../conf'; /** * Create a message diff --git a/src/api/endpoints/messaging/unread.ts b/src/server/api/endpoints/messaging/unread.ts similarity index 100% rename from src/api/endpoints/messaging/unread.ts rename to src/server/api/endpoints/messaging/unread.ts diff --git a/src/api/endpoints/meta.ts b/src/server/api/endpoints/meta.ts similarity index 94% rename from src/api/endpoints/meta.ts rename to src/server/api/endpoints/meta.ts index 1370ead3c..10625ec66 100644 --- a/src/api/endpoints/meta.ts +++ b/src/server/api/endpoints/meta.ts @@ -2,8 +2,8 @@ * Module dependencies */ import * as os from 'os'; -import version from '../../version'; -import config from '../../conf'; +import version from '../../../version'; +import config from '../../../conf'; import Meta from '../models/meta'; /** diff --git a/src/api/endpoints/mute/create.ts b/src/server/api/endpoints/mute/create.ts similarity index 100% rename from src/api/endpoints/mute/create.ts rename to src/server/api/endpoints/mute/create.ts diff --git a/src/api/endpoints/mute/delete.ts b/src/server/api/endpoints/mute/delete.ts similarity index 100% rename from src/api/endpoints/mute/delete.ts rename to src/server/api/endpoints/mute/delete.ts diff --git a/src/api/endpoints/mute/list.ts b/src/server/api/endpoints/mute/list.ts similarity index 100% rename from src/api/endpoints/mute/list.ts rename to src/server/api/endpoints/mute/list.ts diff --git a/src/api/endpoints/my/apps.ts b/src/server/api/endpoints/my/apps.ts similarity index 100% rename from src/api/endpoints/my/apps.ts rename to src/server/api/endpoints/my/apps.ts diff --git a/src/api/endpoints/notifications/get_unread_count.ts b/src/server/api/endpoints/notifications/get_unread_count.ts similarity index 100% rename from src/api/endpoints/notifications/get_unread_count.ts rename to src/server/api/endpoints/notifications/get_unread_count.ts diff --git a/src/api/endpoints/notifications/mark_as_read_all.ts b/src/server/api/endpoints/notifications/mark_as_read_all.ts similarity index 100% rename from src/api/endpoints/notifications/mark_as_read_all.ts rename to src/server/api/endpoints/notifications/mark_as_read_all.ts diff --git a/src/api/endpoints/othello/games.ts b/src/server/api/endpoints/othello/games.ts similarity index 100% rename from src/api/endpoints/othello/games.ts rename to src/server/api/endpoints/othello/games.ts diff --git a/src/api/endpoints/othello/games/show.ts b/src/server/api/endpoints/othello/games/show.ts similarity index 100% rename from src/api/endpoints/othello/games/show.ts rename to src/server/api/endpoints/othello/games/show.ts diff --git a/src/api/endpoints/othello/invitations.ts b/src/server/api/endpoints/othello/invitations.ts similarity index 100% rename from src/api/endpoints/othello/invitations.ts rename to src/server/api/endpoints/othello/invitations.ts diff --git a/src/api/endpoints/othello/match.ts b/src/server/api/endpoints/othello/match.ts similarity index 100% rename from src/api/endpoints/othello/match.ts rename to src/server/api/endpoints/othello/match.ts diff --git a/src/api/endpoints/othello/match/cancel.ts b/src/server/api/endpoints/othello/match/cancel.ts similarity index 100% rename from src/api/endpoints/othello/match/cancel.ts rename to src/server/api/endpoints/othello/match/cancel.ts diff --git a/src/api/endpoints/posts.ts b/src/server/api/endpoints/posts.ts similarity index 100% rename from src/api/endpoints/posts.ts rename to src/server/api/endpoints/posts.ts diff --git a/src/api/endpoints/posts/categorize.ts b/src/server/api/endpoints/posts/categorize.ts similarity index 100% rename from src/api/endpoints/posts/categorize.ts rename to src/server/api/endpoints/posts/categorize.ts diff --git a/src/api/endpoints/posts/context.ts b/src/server/api/endpoints/posts/context.ts similarity index 100% rename from src/api/endpoints/posts/context.ts rename to src/server/api/endpoints/posts/context.ts diff --git a/src/api/endpoints/posts/create.ts b/src/server/api/endpoints/posts/create.ts similarity index 99% rename from src/api/endpoints/posts/create.ts rename to src/server/api/endpoints/posts/create.ts index 286e18bb7..bc9af843b 100644 --- a/src/api/endpoints/posts/create.ts +++ b/src/server/api/endpoints/posts/create.ts @@ -18,7 +18,7 @@ import watch from '../../common/watch-post'; import event, { pushSw, publishChannelStream } from '../../event'; import getAcct from '../../../common/user/get-acct'; import parseAcct from '../../../common/user/parse-acct'; -import config from '../../../conf'; +import config from '../../../../conf'; /** * Create a post diff --git a/src/api/endpoints/posts/favorites/create.ts b/src/server/api/endpoints/posts/favorites/create.ts similarity index 100% rename from src/api/endpoints/posts/favorites/create.ts rename to src/server/api/endpoints/posts/favorites/create.ts diff --git a/src/api/endpoints/posts/favorites/delete.ts b/src/server/api/endpoints/posts/favorites/delete.ts similarity index 100% rename from src/api/endpoints/posts/favorites/delete.ts rename to src/server/api/endpoints/posts/favorites/delete.ts diff --git a/src/api/endpoints/posts/mentions.ts b/src/server/api/endpoints/posts/mentions.ts similarity index 100% rename from src/api/endpoints/posts/mentions.ts rename to src/server/api/endpoints/posts/mentions.ts diff --git a/src/api/endpoints/posts/polls/recommendation.ts b/src/server/api/endpoints/posts/polls/recommendation.ts similarity index 100% rename from src/api/endpoints/posts/polls/recommendation.ts rename to src/server/api/endpoints/posts/polls/recommendation.ts diff --git a/src/api/endpoints/posts/polls/vote.ts b/src/server/api/endpoints/posts/polls/vote.ts similarity index 100% rename from src/api/endpoints/posts/polls/vote.ts rename to src/server/api/endpoints/posts/polls/vote.ts diff --git a/src/api/endpoints/posts/reactions.ts b/src/server/api/endpoints/posts/reactions.ts similarity index 100% rename from src/api/endpoints/posts/reactions.ts rename to src/server/api/endpoints/posts/reactions.ts diff --git a/src/api/endpoints/posts/reactions/create.ts b/src/server/api/endpoints/posts/reactions/create.ts similarity index 100% rename from src/api/endpoints/posts/reactions/create.ts rename to src/server/api/endpoints/posts/reactions/create.ts diff --git a/src/api/endpoints/posts/reactions/delete.ts b/src/server/api/endpoints/posts/reactions/delete.ts similarity index 100% rename from src/api/endpoints/posts/reactions/delete.ts rename to src/server/api/endpoints/posts/reactions/delete.ts diff --git a/src/api/endpoints/posts/replies.ts b/src/server/api/endpoints/posts/replies.ts similarity index 100% rename from src/api/endpoints/posts/replies.ts rename to src/server/api/endpoints/posts/replies.ts diff --git a/src/api/endpoints/posts/reposts.ts b/src/server/api/endpoints/posts/reposts.ts similarity index 100% rename from src/api/endpoints/posts/reposts.ts rename to src/server/api/endpoints/posts/reposts.ts diff --git a/src/api/endpoints/posts/search.ts b/src/server/api/endpoints/posts/search.ts similarity index 100% rename from src/api/endpoints/posts/search.ts rename to src/server/api/endpoints/posts/search.ts diff --git a/src/api/endpoints/posts/show.ts b/src/server/api/endpoints/posts/show.ts similarity index 100% rename from src/api/endpoints/posts/show.ts rename to src/server/api/endpoints/posts/show.ts diff --git a/src/api/endpoints/posts/timeline.ts b/src/server/api/endpoints/posts/timeline.ts similarity index 100% rename from src/api/endpoints/posts/timeline.ts rename to src/server/api/endpoints/posts/timeline.ts diff --git a/src/api/endpoints/posts/trend.ts b/src/server/api/endpoints/posts/trend.ts similarity index 100% rename from src/api/endpoints/posts/trend.ts rename to src/server/api/endpoints/posts/trend.ts diff --git a/src/api/endpoints/stats.ts b/src/server/api/endpoints/stats.ts similarity index 100% rename from src/api/endpoints/stats.ts rename to src/server/api/endpoints/stats.ts diff --git a/src/api/endpoints/sw/register.ts b/src/server/api/endpoints/sw/register.ts similarity index 100% rename from src/api/endpoints/sw/register.ts rename to src/server/api/endpoints/sw/register.ts diff --git a/src/api/endpoints/username/available.ts b/src/server/api/endpoints/username/available.ts similarity index 100% rename from src/api/endpoints/username/available.ts rename to src/server/api/endpoints/username/available.ts diff --git a/src/api/endpoints/users.ts b/src/server/api/endpoints/users.ts similarity index 100% rename from src/api/endpoints/users.ts rename to src/server/api/endpoints/users.ts diff --git a/src/api/endpoints/users/followers.ts b/src/server/api/endpoints/users/followers.ts similarity index 100% rename from src/api/endpoints/users/followers.ts rename to src/server/api/endpoints/users/followers.ts diff --git a/src/api/endpoints/users/following.ts b/src/server/api/endpoints/users/following.ts similarity index 100% rename from src/api/endpoints/users/following.ts rename to src/server/api/endpoints/users/following.ts diff --git a/src/api/endpoints/users/get_frequently_replied_users.ts b/src/server/api/endpoints/users/get_frequently_replied_users.ts similarity index 100% rename from src/api/endpoints/users/get_frequently_replied_users.ts rename to src/server/api/endpoints/users/get_frequently_replied_users.ts diff --git a/src/api/endpoints/users/posts.ts b/src/server/api/endpoints/users/posts.ts similarity index 100% rename from src/api/endpoints/users/posts.ts rename to src/server/api/endpoints/users/posts.ts diff --git a/src/api/endpoints/users/recommendation.ts b/src/server/api/endpoints/users/recommendation.ts similarity index 100% rename from src/api/endpoints/users/recommendation.ts rename to src/server/api/endpoints/users/recommendation.ts diff --git a/src/api/endpoints/users/search.ts b/src/server/api/endpoints/users/search.ts similarity index 98% rename from src/api/endpoints/users/search.ts rename to src/server/api/endpoints/users/search.ts index 39e2ff989..3c8157644 100644 --- a/src/api/endpoints/users/search.ts +++ b/src/server/api/endpoints/users/search.ts @@ -4,7 +4,7 @@ import * as mongo from 'mongodb'; import $ from 'cafy'; import User, { pack } from '../../models/user'; -import config from '../../../conf'; +import config from '../../../../conf'; const escapeRegexp = require('escape-regexp'); /** diff --git a/src/api/endpoints/users/search_by_username.ts b/src/server/api/endpoints/users/search_by_username.ts similarity index 100% rename from src/api/endpoints/users/search_by_username.ts rename to src/server/api/endpoints/users/search_by_username.ts diff --git a/src/api/endpoints/users/show.ts b/src/server/api/endpoints/users/show.ts similarity index 100% rename from src/api/endpoints/users/show.ts rename to src/server/api/endpoints/users/show.ts diff --git a/src/api/event.ts b/src/server/api/event.ts similarity index 98% rename from src/api/event.ts rename to src/server/api/event.ts index 4c9cc18e4..98bf16113 100644 --- a/src/api/event.ts +++ b/src/server/api/event.ts @@ -1,7 +1,7 @@ import * as mongo from 'mongodb'; import * as redis from 'redis'; import swPush from './common/push-sw'; -import config from '../conf'; +import config from '../../conf'; type ID = string | mongo.ObjectID; diff --git a/src/api/limitter.ts b/src/server/api/limitter.ts similarity index 97% rename from src/api/limitter.ts rename to src/server/api/limitter.ts index 9d2c42d33..33337fbb1 100644 --- a/src/api/limitter.ts +++ b/src/server/api/limitter.ts @@ -1,6 +1,6 @@ import * as Limiter from 'ratelimiter'; import * as debug from 'debug'; -import limiterDB from '../db/redis'; +import limiterDB from '../../db/redis'; import { Endpoint } from './endpoints'; import { IAuthContext } from './authenticate'; import getAcct from '../common/user/get-acct'; diff --git a/src/api/models/access-token.ts b/src/server/api/models/access-token.ts similarity index 86% rename from src/api/models/access-token.ts rename to src/server/api/models/access-token.ts index 9985be501..2bf91f309 100644 --- a/src/api/models/access-token.ts +++ b/src/server/api/models/access-token.ts @@ -1,4 +1,4 @@ -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; const collection = db.get('access_tokens'); diff --git a/src/api/models/app.ts b/src/server/api/models/app.ts similarity index 96% rename from src/api/models/app.ts rename to src/server/api/models/app.ts index 34e9867db..17db82eca 100644 --- a/src/api/models/app.ts +++ b/src/server/api/models/app.ts @@ -1,8 +1,8 @@ import * as mongo from 'mongodb'; import deepcopy = require('deepcopy'); import AccessToken from './access-token'; -import db from '../../db/mongodb'; -import config from '../../conf'; +import db from '../../../db/mongodb'; +import config from '../../../conf'; const App = db.get('apps'); App.createIndex('name_id'); diff --git a/src/api/models/appdata.ts b/src/server/api/models/appdata.ts similarity index 63% rename from src/api/models/appdata.ts rename to src/server/api/models/appdata.ts index 3e68354fa..dda3c9893 100644 --- a/src/api/models/appdata.ts +++ b/src/server/api/models/appdata.ts @@ -1,3 +1,3 @@ -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; export default db.get('appdata') as any; // fuck type definition diff --git a/src/api/models/auth-session.ts b/src/server/api/models/auth-session.ts similarity index 95% rename from src/api/models/auth-session.ts rename to src/server/api/models/auth-session.ts index 997ec61c2..a79d901df 100644 --- a/src/api/models/auth-session.ts +++ b/src/server/api/models/auth-session.ts @@ -1,6 +1,6 @@ import * as mongo from 'mongodb'; import deepcopy = require('deepcopy'); -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; import { pack as packApp } from './app'; const AuthSession = db.get('auth_sessions'); diff --git a/src/api/models/channel-watching.ts b/src/server/api/models/channel-watching.ts similarity index 66% rename from src/api/models/channel-watching.ts rename to src/server/api/models/channel-watching.ts index 6184ae408..4c6fae28d 100644 --- a/src/api/models/channel-watching.ts +++ b/src/server/api/models/channel-watching.ts @@ -1,3 +1,3 @@ -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; export default db.get('channel_watching') as any; // fuck type definition diff --git a/src/api/models/channel.ts b/src/server/api/models/channel.ts similarity index 97% rename from src/api/models/channel.ts rename to src/server/api/models/channel.ts index 815d53593..97999bd9e 100644 --- a/src/api/models/channel.ts +++ b/src/server/api/models/channel.ts @@ -2,7 +2,7 @@ import * as mongo from 'mongodb'; import deepcopy = require('deepcopy'); import { IUser } from './user'; import Watching from './channel-watching'; -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; const Channel = db.get('channels'); export default Channel; diff --git a/src/api/models/drive-file.ts b/src/server/api/models/drive-file.ts similarity index 96% rename from src/api/models/drive-file.ts rename to src/server/api/models/drive-file.ts index 2a46d8dc4..851a79a0e 100644 --- a/src/api/models/drive-file.ts +++ b/src/server/api/models/drive-file.ts @@ -1,8 +1,8 @@ import * as mongodb from 'mongodb'; import deepcopy = require('deepcopy'); import { pack as packFolder } from './drive-folder'; -import config from '../../conf'; -import monkDb, { nativeDbConn } from '../../db/mongodb'; +import config from '../../../conf'; +import monkDb, { nativeDbConn } from '../../../db/mongodb'; const DriveFile = monkDb.get('drive_files.files'); diff --git a/src/api/models/drive-folder.ts b/src/server/api/models/drive-folder.ts similarity index 97% rename from src/api/models/drive-folder.ts rename to src/server/api/models/drive-folder.ts index 54b45049b..505556376 100644 --- a/src/api/models/drive-folder.ts +++ b/src/server/api/models/drive-folder.ts @@ -1,6 +1,6 @@ import * as mongo from 'mongodb'; import deepcopy = require('deepcopy'); -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; import DriveFile from './drive-file'; const DriveFolder = db.get('drive_folders'); diff --git a/src/api/models/drive-tag.ts b/src/server/api/models/drive-tag.ts similarity index 64% rename from src/api/models/drive-tag.ts rename to src/server/api/models/drive-tag.ts index 991c935e8..d1c68365a 100644 --- a/src/api/models/drive-tag.ts +++ b/src/server/api/models/drive-tag.ts @@ -1,3 +1,3 @@ -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; export default db.get('drive_tags') as any; // fuck type definition diff --git a/src/api/models/favorite.ts b/src/server/api/models/favorite.ts similarity index 64% rename from src/api/models/favorite.ts rename to src/server/api/models/favorite.ts index e01d9e343..314261764 100644 --- a/src/api/models/favorite.ts +++ b/src/server/api/models/favorite.ts @@ -1,3 +1,3 @@ -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; export default db.get('favorites') as any; // fuck type definition diff --git a/src/api/models/following.ts b/src/server/api/models/following.ts similarity index 64% rename from src/api/models/following.ts rename to src/server/api/models/following.ts index cb3db9b53..92d7b6d31 100644 --- a/src/api/models/following.ts +++ b/src/server/api/models/following.ts @@ -1,3 +1,3 @@ -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; export default db.get('following') as any; // fuck type definition diff --git a/src/api/models/messaging-history.ts b/src/server/api/models/messaging-history.ts similarity index 67% rename from src/api/models/messaging-history.ts rename to src/server/api/models/messaging-history.ts index c06987e45..ea9f317ee 100644 --- a/src/api/models/messaging-history.ts +++ b/src/server/api/models/messaging-history.ts @@ -1,3 +1,3 @@ -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; export default db.get('messaging_histories') as any; // fuck type definition diff --git a/src/api/models/messaging-message.ts b/src/server/api/models/messaging-message.ts similarity index 97% rename from src/api/models/messaging-message.ts rename to src/server/api/models/messaging-message.ts index fcb356c5c..be484d635 100644 --- a/src/api/models/messaging-message.ts +++ b/src/server/api/models/messaging-message.ts @@ -2,7 +2,7 @@ import * as mongo from 'mongodb'; import deepcopy = require('deepcopy'); import { pack as packUser } from './user'; import { pack as packFile } from './drive-file'; -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; import parse from '../common/text'; const MessagingMessage = db.get('messaging_messages'); diff --git a/src/api/models/meta.ts b/src/server/api/models/meta.ts similarity index 74% rename from src/api/models/meta.ts rename to src/server/api/models/meta.ts index c7dba8fcb..ee1ada18f 100644 --- a/src/api/models/meta.ts +++ b/src/server/api/models/meta.ts @@ -1,4 +1,4 @@ -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; export default db.get('meta') as any; // fuck type definition diff --git a/src/api/models/mute.ts b/src/server/api/models/mute.ts similarity index 62% rename from src/api/models/mute.ts rename to src/server/api/models/mute.ts index 16018b82f..02f652c30 100644 --- a/src/api/models/mute.ts +++ b/src/server/api/models/mute.ts @@ -1,3 +1,3 @@ -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; export default db.get('mute') as any; // fuck type definition diff --git a/src/api/models/notification.ts b/src/server/api/models/notification.ts similarity index 98% rename from src/api/models/notification.ts rename to src/server/api/models/notification.ts index fa7049d31..bcb25534d 100644 --- a/src/api/models/notification.ts +++ b/src/server/api/models/notification.ts @@ -1,6 +1,6 @@ import * as mongo from 'mongodb'; import deepcopy = require('deepcopy'); -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; import { IUser, pack as packUser } from './user'; import { pack as packPost } from './post'; diff --git a/src/api/models/othello-game.ts b/src/server/api/models/othello-game.ts similarity index 98% rename from src/api/models/othello-game.ts rename to src/server/api/models/othello-game.ts index 01c6ca6c0..97508e46d 100644 --- a/src/api/models/othello-game.ts +++ b/src/server/api/models/othello-game.ts @@ -1,6 +1,6 @@ import * as mongo from 'mongodb'; import deepcopy = require('deepcopy'); -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; import { IUser, pack as packUser } from './user'; const Game = db.get('othello_games'); diff --git a/src/api/models/othello-matching.ts b/src/server/api/models/othello-matching.ts similarity index 96% rename from src/api/models/othello-matching.ts rename to src/server/api/models/othello-matching.ts index 5cc39cae1..3c29e6a00 100644 --- a/src/api/models/othello-matching.ts +++ b/src/server/api/models/othello-matching.ts @@ -1,6 +1,6 @@ import * as mongo from 'mongodb'; import deepcopy = require('deepcopy'); -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; import { IUser, pack as packUser } from './user'; const Matching = db.get('othello_matchings'); diff --git a/src/api/models/poll-vote.ts b/src/server/api/models/poll-vote.ts similarity index 64% rename from src/api/models/poll-vote.ts rename to src/server/api/models/poll-vote.ts index af77a2643..c6638ccf1 100644 --- a/src/api/models/poll-vote.ts +++ b/src/server/api/models/poll-vote.ts @@ -1,3 +1,3 @@ -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; export default db.get('poll_votes') as any; // fuck type definition diff --git a/src/api/models/post-reaction.ts b/src/server/api/models/post-reaction.ts similarity index 96% rename from src/api/models/post-reaction.ts rename to src/server/api/models/post-reaction.ts index 639a70e00..5cd122d76 100644 --- a/src/api/models/post-reaction.ts +++ b/src/server/api/models/post-reaction.ts @@ -1,6 +1,6 @@ import * as mongo from 'mongodb'; import deepcopy = require('deepcopy'); -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; import Reaction from './post-reaction'; import { pack as packUser } from './user'; diff --git a/src/api/models/post-watching.ts b/src/server/api/models/post-watching.ts similarity index 65% rename from src/api/models/post-watching.ts rename to src/server/api/models/post-watching.ts index 41d37e270..9a4163c8d 100644 --- a/src/api/models/post-watching.ts +++ b/src/server/api/models/post-watching.ts @@ -1,3 +1,3 @@ -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; export default db.get('post_watching') as any; // fuck type definition diff --git a/src/api/models/post.ts b/src/server/api/models/post.ts similarity index 99% rename from src/api/models/post.ts rename to src/server/api/models/post.ts index c37c8371c..3f648e08c 100644 --- a/src/api/models/post.ts +++ b/src/server/api/models/post.ts @@ -1,7 +1,7 @@ import * as mongo from 'mongodb'; import deepcopy = require('deepcopy'); import rap from '@prezzemolo/rap'; -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; import { IUser, pack as packUser } from './user'; import { pack as packApp } from './app'; import { pack as packChannel } from './channel'; diff --git a/src/api/models/signin.ts b/src/server/api/models/signin.ts similarity index 93% rename from src/api/models/signin.ts rename to src/server/api/models/signin.ts index 262c8707e..5cffb3c31 100644 --- a/src/api/models/signin.ts +++ b/src/server/api/models/signin.ts @@ -1,6 +1,6 @@ import * as mongo from 'mongodb'; import deepcopy = require('deepcopy'); -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; const Signin = db.get('signin'); export default Signin; diff --git a/src/api/models/sw-subscription.ts b/src/server/api/models/sw-subscription.ts similarity index 66% rename from src/api/models/sw-subscription.ts rename to src/server/api/models/sw-subscription.ts index ecca04cb9..4506a982f 100644 --- a/src/api/models/sw-subscription.ts +++ b/src/server/api/models/sw-subscription.ts @@ -1,3 +1,3 @@ -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; export default db.get('sw_subscriptions') as any; // fuck type definition diff --git a/src/api/models/user.ts b/src/server/api/models/user.ts similarity index 99% rename from src/api/models/user.ts rename to src/server/api/models/user.ts index e73c95faf..8e7d50baa 100644 --- a/src/api/models/user.ts +++ b/src/server/api/models/user.ts @@ -1,12 +1,12 @@ import * as mongo from 'mongodb'; import deepcopy = require('deepcopy'); import rap from '@prezzemolo/rap'; -import db from '../../db/mongodb'; +import db from '../../../db/mongodb'; import { IPost, pack as packPost } from './post'; import Following from './following'; import Mute from './mute'; import getFriends from '../common/get-friends'; -import config from '../../conf'; +import config from '../../../conf'; const User = db.get('users'); diff --git a/src/api/private/signin.ts b/src/server/api/private/signin.ts similarity index 98% rename from src/api/private/signin.ts rename to src/server/api/private/signin.ts index 00dcb8afc..bbc990899 100644 --- a/src/api/private/signin.ts +++ b/src/server/api/private/signin.ts @@ -5,7 +5,7 @@ import { default as User, ILocalAccount, IUser } from '../models/user'; import Signin, { pack } from '../models/signin'; import event from '../event'; import signin from '../common/signin'; -import config from '../../conf'; +import config from '../../../conf'; export default async (req: express.Request, res: express.Response) => { res.header('Access-Control-Allow-Origin', config.url); diff --git a/src/api/private/signup.ts b/src/server/api/private/signup.ts similarity index 96% rename from src/api/private/signup.ts rename to src/server/api/private/signup.ts index 96e049570..9f5539331 100644 --- a/src/api/private/signup.ts +++ b/src/server/api/private/signup.ts @@ -1,11 +1,11 @@ import * as uuid from 'uuid'; import * as express from 'express'; import * as bcrypt from 'bcryptjs'; -import { generate as generateKeypair } from '../../crypto_key'; +import { generate as generateKeypair } from '../../../crypto_key'; import recaptcha = require('recaptcha-promise'); import User, { IUser, validateUsername, validatePassword, pack } from '../models/user'; import generateUserToken from '../common/generate-native-user-token'; -import config from '../../conf'; +import config from '../../../conf'; recaptcha.init({ secret_key: config.recaptcha.secret_key diff --git a/src/api/reply.ts b/src/server/api/reply.ts similarity index 100% rename from src/api/reply.ts rename to src/server/api/reply.ts diff --git a/src/api/server.ts b/src/server/api/server.ts similarity index 100% rename from src/api/server.ts rename to src/server/api/server.ts diff --git a/src/api/service/github.ts b/src/server/api/service/github.ts similarity index 77% rename from src/api/service/github.ts rename to src/server/api/service/github.ts index 1c78267c0..a33d35975 100644 --- a/src/api/service/github.ts +++ b/src/server/api/service/github.ts @@ -1,9 +1,9 @@ import * as EventEmitter from 'events'; import * as express from 'express'; -import * as request from 'request'; const crypto = require('crypto'); import User from '../models/user'; -import config from '../../conf'; +import config from '../../../conf'; +import queue from '../../../queue'; module.exports = async (app: express.Application) => { if (config.github_bot == null) return; @@ -25,12 +25,12 @@ module.exports = async (app: express.Application) => { // req.headers['x-hub-signature'] および // req.headers['x-github-event'] は常に string ですが、型定義の都合上 // string | string[] になっているので string を明示しています - if ((new Buffer(req.headers['x-hub-signature'] as string)).equals(new Buffer(`sha1=${crypto.createHmac('sha1', config.github_bot.hook_secret).update(JSON.stringify(req.body)).digest('hex')}`))) { +// if ((new Buffer(req.headers['x-hub-signature'] as string)).equals(new Buffer(`sha1=${crypto.createHmac('sha1', config.github_bot.hook_secret).update(JSON.stringify(req.body)).digest('hex')}`))) { handler.emit(req.headers['x-github-event'] as string, req.body); res.sendStatus(200); - } else { - res.sendStatus(400); - } +// } else { +// res.sendStatus(400); +// } }); handler.on('status', event => { @@ -41,26 +41,12 @@ module.exports = async (app: express.Application) => { const commit = event.commit; const parent = commit.parents[0]; - // Fetch parent status - request({ - url: `${parent.url}/statuses`, - headers: { - 'User-Agent': 'misskey' - } - }, (err, res, body) => { - if (err) { - console.error(err); - return; - } - const parentStatuses = JSON.parse(body); - const parentState = parentStatuses[0].state; - const stillFailed = parentState == 'failure' || parentState == 'error'; - if (stillFailed) { - post(`**⚠️BUILD STILL FAILED⚠️**: ?[${commit.commit.message}](${commit.html_url})`); - } else { - post(`**🚨BUILD FAILED🚨**: →→→?[${commit.commit.message}](${commit.html_url})←←←`); - } - }); + queue.create('gitHubFailureReport', { + userId: bot._id, + parentUrl: parent.url, + htmlUrl: commit.html_url, + message: commit.commit.message, + }).save(); break; } }); diff --git a/src/api/service/twitter.ts b/src/server/api/service/twitter.ts similarity index 98% rename from src/api/service/twitter.ts rename to src/server/api/service/twitter.ts index c1f2e48a6..861f63ed6 100644 --- a/src/api/service/twitter.ts +++ b/src/server/api/service/twitter.ts @@ -4,10 +4,10 @@ import * as uuid from 'uuid'; // import * as Twitter from 'twitter'; // const Twitter = require('twitter'); import autwh from 'autwh'; -import redis from '../../db/redis'; +import redis from '../../../db/redis'; import User, { pack } from '../models/user'; import event from '../event'; -import config from '../../conf'; +import config from '../../../conf'; import signin from '../common/signin'; module.exports = (app: express.Application) => { diff --git a/src/api/stream/channel.ts b/src/server/api/stream/channel.ts similarity index 100% rename from src/api/stream/channel.ts rename to src/server/api/stream/channel.ts diff --git a/src/api/stream/drive.ts b/src/server/api/stream/drive.ts similarity index 100% rename from src/api/stream/drive.ts rename to src/server/api/stream/drive.ts diff --git a/src/api/stream/home.ts b/src/server/api/stream/home.ts similarity index 100% rename from src/api/stream/home.ts rename to src/server/api/stream/home.ts diff --git a/src/api/stream/messaging-index.ts b/src/server/api/stream/messaging-index.ts similarity index 100% rename from src/api/stream/messaging-index.ts rename to src/server/api/stream/messaging-index.ts diff --git a/src/api/stream/messaging.ts b/src/server/api/stream/messaging.ts similarity index 100% rename from src/api/stream/messaging.ts rename to src/server/api/stream/messaging.ts diff --git a/src/api/stream/othello-game.ts b/src/server/api/stream/othello-game.ts similarity index 100% rename from src/api/stream/othello-game.ts rename to src/server/api/stream/othello-game.ts diff --git a/src/api/stream/othello.ts b/src/server/api/stream/othello.ts similarity index 100% rename from src/api/stream/othello.ts rename to src/server/api/stream/othello.ts diff --git a/src/api/stream/requests.ts b/src/server/api/stream/requests.ts similarity index 100% rename from src/api/stream/requests.ts rename to src/server/api/stream/requests.ts diff --git a/src/api/stream/server.ts b/src/server/api/stream/server.ts similarity index 100% rename from src/api/stream/server.ts rename to src/server/api/stream/server.ts diff --git a/src/api/streaming.ts b/src/server/api/streaming.ts similarity index 98% rename from src/api/streaming.ts rename to src/server/api/streaming.ts index a6759e414..95f444e00 100644 --- a/src/api/streaming.ts +++ b/src/server/api/streaming.ts @@ -1,7 +1,7 @@ import * as http from 'http'; import * as websocket from 'websocket'; import * as redis from 'redis'; -import config from '../conf'; +import config from '../../conf'; import { default as User, IUser } from './models/user'; import AccessToken from './models/access-token'; import isNativeToken from './common/is-native-token'; diff --git a/src/common/get-notification-summary.ts b/src/server/common/get-notification-summary.ts similarity index 100% rename from src/common/get-notification-summary.ts rename to src/server/common/get-notification-summary.ts diff --git a/src/common/get-post-summary.ts b/src/server/common/get-post-summary.ts similarity index 100% rename from src/common/get-post-summary.ts rename to src/server/common/get-post-summary.ts diff --git a/src/common/get-reaction-emoji.ts b/src/server/common/get-reaction-emoji.ts similarity index 100% rename from src/common/get-reaction-emoji.ts rename to src/server/common/get-reaction-emoji.ts diff --git a/src/common/othello/ai/back.ts b/src/server/common/othello/ai/back.ts similarity index 99% rename from src/common/othello/ai/back.ts rename to src/server/common/othello/ai/back.ts index 27dbc3952..c20c6fed2 100644 --- a/src/common/othello/ai/back.ts +++ b/src/server/common/othello/ai/back.ts @@ -8,7 +8,7 @@ import * as request from 'request-promise-native'; import Othello, { Color } from '../core'; -import conf from '../../../conf'; +import conf from '../../../../conf'; let game; let form; diff --git a/src/common/othello/ai/front.ts b/src/server/common/othello/ai/front.ts similarity index 99% rename from src/common/othello/ai/front.ts rename to src/server/common/othello/ai/front.ts index d892afbed..af0b748fc 100644 --- a/src/common/othello/ai/front.ts +++ b/src/server/common/othello/ai/front.ts @@ -10,7 +10,7 @@ import * as childProcess from 'child_process'; const WebSocket = require('ws'); import * as ReconnectingWebSocket from 'reconnecting-websocket'; import * as request from 'request-promise-native'; -import conf from '../../../conf'; +import conf from '../../../../conf'; // 設定 //////////////////////////////////////////////////////// diff --git a/src/common/othello/ai/index.ts b/src/server/common/othello/ai/index.ts similarity index 100% rename from src/common/othello/ai/index.ts rename to src/server/common/othello/ai/index.ts diff --git a/src/common/othello/core.ts b/src/server/common/othello/core.ts similarity index 100% rename from src/common/othello/core.ts rename to src/server/common/othello/core.ts diff --git a/src/common/othello/maps.ts b/src/server/common/othello/maps.ts similarity index 100% rename from src/common/othello/maps.ts rename to src/server/common/othello/maps.ts diff --git a/src/common/user/get-acct.ts b/src/server/common/user/get-acct.ts similarity index 100% rename from src/common/user/get-acct.ts rename to src/server/common/user/get-acct.ts diff --git a/src/common/user/get-summary.ts b/src/server/common/user/get-summary.ts similarity index 100% rename from src/common/user/get-summary.ts rename to src/server/common/user/get-summary.ts diff --git a/src/common/user/parse-acct.ts b/src/server/common/user/parse-acct.ts similarity index 100% rename from src/common/user/parse-acct.ts rename to src/server/common/user/parse-acct.ts diff --git a/src/file/assets/avatar.jpg b/src/server/file/assets/avatar.jpg similarity index 100% rename from src/file/assets/avatar.jpg rename to src/server/file/assets/avatar.jpg diff --git a/src/file/assets/bad-egg.png b/src/server/file/assets/bad-egg.png similarity index 100% rename from src/file/assets/bad-egg.png rename to src/server/file/assets/bad-egg.png diff --git a/src/file/assets/dummy.png b/src/server/file/assets/dummy.png similarity index 100% rename from src/file/assets/dummy.png rename to src/server/file/assets/dummy.png diff --git a/src/file/assets/not-an-image.png b/src/server/file/assets/not-an-image.png similarity index 100% rename from src/file/assets/not-an-image.png rename to src/server/file/assets/not-an-image.png diff --git a/src/file/assets/thumbnail-not-available.png b/src/server/file/assets/thumbnail-not-available.png similarity index 100% rename from src/file/assets/thumbnail-not-available.png rename to src/server/file/assets/thumbnail-not-available.png diff --git a/src/file/server.ts b/src/server/file/server.ts similarity index 100% rename from src/file/server.ts rename to src/server/file/server.ts diff --git a/src/server.ts b/src/server/index.ts similarity index 77% rename from src/server.ts rename to src/server/index.ts index 0e030002a..3908b8a52 100644 --- a/src/server.ts +++ b/src/server/index.ts @@ -5,13 +5,12 @@ import * as fs from 'fs'; import * as http from 'http'; import * as https from 'https'; -import * as cluster from 'cluster'; import * as express from 'express'; import * as morgan from 'morgan'; import Accesses from 'accesses'; import log from './log-request'; -import config from './conf'; +import config from '../conf'; /** * Init app @@ -56,10 +55,7 @@ app.use('/api', require('./api/server')); app.use('/files', require('./file/server')); app.use(require('./web/server')); -/** - * Create server - */ -const server = (() => { +function createServer() { if (config.https) { const certs = {}; Object.keys(config.https).forEach(k => { @@ -69,24 +65,18 @@ const server = (() => { } else { return http.createServer(app); } -})(); +} -/** - * Steaming - */ -require('./api/streaming')(server); +export default () => new Promise(resolve => { + const server = createServer(); -/** - * Server listen - */ -server.listen(config.port, () => { - if (cluster.isWorker) { - // Send a 'ready' message to parent process - process.send('ready'); - } + /** + * Steaming + */ + require('./api/streaming')(server); + + /** + * Server listen + */ + server.listen(config.port, resolve); }); - -/** - * Export app for testing - */ -module.exports = app; diff --git a/src/log-request.ts b/src/server/log-request.ts similarity index 100% rename from src/log-request.ts rename to src/server/log-request.ts diff --git a/src/web/app/animation.styl b/src/server/web/app/animation.styl similarity index 100% rename from src/web/app/animation.styl rename to src/server/web/app/animation.styl diff --git a/src/web/app/app.styl b/src/server/web/app/app.styl similarity index 100% rename from src/web/app/app.styl rename to src/server/web/app/app.styl diff --git a/src/web/app/app.vue b/src/server/web/app/app.vue similarity index 100% rename from src/web/app/app.vue rename to src/server/web/app/app.vue diff --git a/src/web/app/auth/assets/logo.svg b/src/server/web/app/auth/assets/logo.svg similarity index 100% rename from src/web/app/auth/assets/logo.svg rename to src/server/web/app/auth/assets/logo.svg diff --git a/src/web/app/auth/script.ts b/src/server/web/app/auth/script.ts similarity index 100% rename from src/web/app/auth/script.ts rename to src/server/web/app/auth/script.ts diff --git a/src/web/app/auth/style.styl b/src/server/web/app/auth/style.styl similarity index 100% rename from src/web/app/auth/style.styl rename to src/server/web/app/auth/style.styl diff --git a/src/web/app/auth/views/form.vue b/src/server/web/app/auth/views/form.vue similarity index 100% rename from src/web/app/auth/views/form.vue rename to src/server/web/app/auth/views/form.vue diff --git a/src/web/app/auth/views/index.vue b/src/server/web/app/auth/views/index.vue similarity index 100% rename from src/web/app/auth/views/index.vue rename to src/server/web/app/auth/views/index.vue diff --git a/src/web/app/base.pug b/src/server/web/app/base.pug similarity index 76% rename from src/web/app/base.pug rename to src/server/web/app/base.pug index d7c7f0aed..60eb1539e 100644 --- a/src/web/app/base.pug +++ b/src/server/web/app/base.pug @@ -14,12 +14,12 @@ html title Misskey style - include ./../../../built/web/assets/init.css + include ./../../../../built/server/web/assets/init.css script - include ./../../../built/web/assets/boot.js + include ./../../../../built/server/web/assets/boot.js script - include ./../../../built/web/assets/safe.js + include ./../../../../built/server/web/assets/safe.js //- FontAwesome style style #{facss} diff --git a/src/web/app/boot.js b/src/server/web/app/boot.js similarity index 100% rename from src/web/app/boot.js rename to src/server/web/app/boot.js diff --git a/src/web/app/ch/script.ts b/src/server/web/app/ch/script.ts similarity index 100% rename from src/web/app/ch/script.ts rename to src/server/web/app/ch/script.ts diff --git a/src/web/app/ch/style.styl b/src/server/web/app/ch/style.styl similarity index 100% rename from src/web/app/ch/style.styl rename to src/server/web/app/ch/style.styl diff --git a/src/web/app/ch/tags/channel.tag b/src/server/web/app/ch/tags/channel.tag similarity index 100% rename from src/web/app/ch/tags/channel.tag rename to src/server/web/app/ch/tags/channel.tag diff --git a/src/web/app/ch/tags/header.tag b/src/server/web/app/ch/tags/header.tag similarity index 100% rename from src/web/app/ch/tags/header.tag rename to src/server/web/app/ch/tags/header.tag diff --git a/src/web/app/ch/tags/index.tag b/src/server/web/app/ch/tags/index.tag similarity index 100% rename from src/web/app/ch/tags/index.tag rename to src/server/web/app/ch/tags/index.tag diff --git a/src/web/app/ch/tags/index.ts b/src/server/web/app/ch/tags/index.ts similarity index 100% rename from src/web/app/ch/tags/index.ts rename to src/server/web/app/ch/tags/index.ts diff --git a/src/web/app/common/define-widget.ts b/src/server/web/app/common/define-widget.ts similarity index 100% rename from src/web/app/common/define-widget.ts rename to src/server/web/app/common/define-widget.ts diff --git a/src/web/app/common/mios.ts b/src/server/web/app/common/mios.ts similarity index 100% rename from src/web/app/common/mios.ts rename to src/server/web/app/common/mios.ts diff --git a/src/web/app/common/scripts/check-for-update.ts b/src/server/web/app/common/scripts/check-for-update.ts similarity index 100% rename from src/web/app/common/scripts/check-for-update.ts rename to src/server/web/app/common/scripts/check-for-update.ts diff --git a/src/web/app/common/scripts/compose-notification.ts b/src/server/web/app/common/scripts/compose-notification.ts similarity index 100% rename from src/web/app/common/scripts/compose-notification.ts rename to src/server/web/app/common/scripts/compose-notification.ts diff --git a/src/web/app/common/scripts/contains.ts b/src/server/web/app/common/scripts/contains.ts similarity index 100% rename from src/web/app/common/scripts/contains.ts rename to src/server/web/app/common/scripts/contains.ts diff --git a/src/web/app/common/scripts/copy-to-clipboard.ts b/src/server/web/app/common/scripts/copy-to-clipboard.ts similarity index 100% rename from src/web/app/common/scripts/copy-to-clipboard.ts rename to src/server/web/app/common/scripts/copy-to-clipboard.ts diff --git a/src/web/app/common/scripts/date-stringify.ts b/src/server/web/app/common/scripts/date-stringify.ts similarity index 100% rename from src/web/app/common/scripts/date-stringify.ts rename to src/server/web/app/common/scripts/date-stringify.ts diff --git a/src/web/app/common/scripts/fuck-ad-block.ts b/src/server/web/app/common/scripts/fuck-ad-block.ts similarity index 100% rename from src/web/app/common/scripts/fuck-ad-block.ts rename to src/server/web/app/common/scripts/fuck-ad-block.ts diff --git a/src/web/app/common/scripts/gcd.ts b/src/server/web/app/common/scripts/gcd.ts similarity index 100% rename from src/web/app/common/scripts/gcd.ts rename to src/server/web/app/common/scripts/gcd.ts diff --git a/src/web/app/common/scripts/get-kao.ts b/src/server/web/app/common/scripts/get-kao.ts similarity index 100% rename from src/web/app/common/scripts/get-kao.ts rename to src/server/web/app/common/scripts/get-kao.ts diff --git a/src/web/app/common/scripts/get-median.ts b/src/server/web/app/common/scripts/get-median.ts similarity index 100% rename from src/web/app/common/scripts/get-median.ts rename to src/server/web/app/common/scripts/get-median.ts diff --git a/src/web/app/common/scripts/loading.ts b/src/server/web/app/common/scripts/loading.ts similarity index 100% rename from src/web/app/common/scripts/loading.ts rename to src/server/web/app/common/scripts/loading.ts diff --git a/src/web/app/common/scripts/parse-search-query.ts b/src/server/web/app/common/scripts/parse-search-query.ts similarity index 100% rename from src/web/app/common/scripts/parse-search-query.ts rename to src/server/web/app/common/scripts/parse-search-query.ts diff --git a/src/web/app/common/scripts/streaming/channel.ts b/src/server/web/app/common/scripts/streaming/channel.ts similarity index 100% rename from src/web/app/common/scripts/streaming/channel.ts rename to src/server/web/app/common/scripts/streaming/channel.ts diff --git a/src/web/app/common/scripts/streaming/drive.ts b/src/server/web/app/common/scripts/streaming/drive.ts similarity index 100% rename from src/web/app/common/scripts/streaming/drive.ts rename to src/server/web/app/common/scripts/streaming/drive.ts diff --git a/src/web/app/common/scripts/streaming/home.ts b/src/server/web/app/common/scripts/streaming/home.ts similarity index 100% rename from src/web/app/common/scripts/streaming/home.ts rename to src/server/web/app/common/scripts/streaming/home.ts diff --git a/src/web/app/common/scripts/streaming/messaging-index.ts b/src/server/web/app/common/scripts/streaming/messaging-index.ts similarity index 100% rename from src/web/app/common/scripts/streaming/messaging-index.ts rename to src/server/web/app/common/scripts/streaming/messaging-index.ts diff --git a/src/web/app/common/scripts/streaming/messaging.ts b/src/server/web/app/common/scripts/streaming/messaging.ts similarity index 100% rename from src/web/app/common/scripts/streaming/messaging.ts rename to src/server/web/app/common/scripts/streaming/messaging.ts diff --git a/src/web/app/common/scripts/streaming/othello-game.ts b/src/server/web/app/common/scripts/streaming/othello-game.ts similarity index 100% rename from src/web/app/common/scripts/streaming/othello-game.ts rename to src/server/web/app/common/scripts/streaming/othello-game.ts diff --git a/src/web/app/common/scripts/streaming/othello.ts b/src/server/web/app/common/scripts/streaming/othello.ts similarity index 100% rename from src/web/app/common/scripts/streaming/othello.ts rename to src/server/web/app/common/scripts/streaming/othello.ts diff --git a/src/web/app/common/scripts/streaming/requests.ts b/src/server/web/app/common/scripts/streaming/requests.ts similarity index 100% rename from src/web/app/common/scripts/streaming/requests.ts rename to src/server/web/app/common/scripts/streaming/requests.ts diff --git a/src/web/app/common/scripts/streaming/server.ts b/src/server/web/app/common/scripts/streaming/server.ts similarity index 100% rename from src/web/app/common/scripts/streaming/server.ts rename to src/server/web/app/common/scripts/streaming/server.ts diff --git a/src/web/app/common/scripts/streaming/stream-manager.ts b/src/server/web/app/common/scripts/streaming/stream-manager.ts similarity index 100% rename from src/web/app/common/scripts/streaming/stream-manager.ts rename to src/server/web/app/common/scripts/streaming/stream-manager.ts diff --git a/src/web/app/common/scripts/streaming/stream.ts b/src/server/web/app/common/scripts/streaming/stream.ts similarity index 100% rename from src/web/app/common/scripts/streaming/stream.ts rename to src/server/web/app/common/scripts/streaming/stream.ts diff --git a/src/web/app/common/views/components/autocomplete.vue b/src/server/web/app/common/views/components/autocomplete.vue similarity index 100% rename from src/web/app/common/views/components/autocomplete.vue rename to src/server/web/app/common/views/components/autocomplete.vue diff --git a/src/web/app/common/views/components/connect-failed.troubleshooter.vue b/src/server/web/app/common/views/components/connect-failed.troubleshooter.vue similarity index 100% rename from src/web/app/common/views/components/connect-failed.troubleshooter.vue rename to src/server/web/app/common/views/components/connect-failed.troubleshooter.vue diff --git a/src/web/app/common/views/components/connect-failed.vue b/src/server/web/app/common/views/components/connect-failed.vue similarity index 100% rename from src/web/app/common/views/components/connect-failed.vue rename to src/server/web/app/common/views/components/connect-failed.vue diff --git a/src/web/app/common/views/components/ellipsis.vue b/src/server/web/app/common/views/components/ellipsis.vue similarity index 100% rename from src/web/app/common/views/components/ellipsis.vue rename to src/server/web/app/common/views/components/ellipsis.vue diff --git a/src/web/app/common/views/components/file-type-icon.vue b/src/server/web/app/common/views/components/file-type-icon.vue similarity index 100% rename from src/web/app/common/views/components/file-type-icon.vue rename to src/server/web/app/common/views/components/file-type-icon.vue diff --git a/src/web/app/common/views/components/forkit.vue b/src/server/web/app/common/views/components/forkit.vue similarity index 100% rename from src/web/app/common/views/components/forkit.vue rename to src/server/web/app/common/views/components/forkit.vue diff --git a/src/web/app/common/views/components/index.ts b/src/server/web/app/common/views/components/index.ts similarity index 100% rename from src/web/app/common/views/components/index.ts rename to src/server/web/app/common/views/components/index.ts diff --git a/src/web/app/common/views/components/media-list.vue b/src/server/web/app/common/views/components/media-list.vue similarity index 100% rename from src/web/app/common/views/components/media-list.vue rename to src/server/web/app/common/views/components/media-list.vue diff --git a/src/web/app/common/views/components/messaging-room.form.vue b/src/server/web/app/common/views/components/messaging-room.form.vue similarity index 100% rename from src/web/app/common/views/components/messaging-room.form.vue rename to src/server/web/app/common/views/components/messaging-room.form.vue diff --git a/src/web/app/common/views/components/messaging-room.message.vue b/src/server/web/app/common/views/components/messaging-room.message.vue similarity index 100% rename from src/web/app/common/views/components/messaging-room.message.vue rename to src/server/web/app/common/views/components/messaging-room.message.vue diff --git a/src/web/app/common/views/components/messaging-room.vue b/src/server/web/app/common/views/components/messaging-room.vue similarity index 100% rename from src/web/app/common/views/components/messaging-room.vue rename to src/server/web/app/common/views/components/messaging-room.vue diff --git a/src/web/app/common/views/components/messaging.vue b/src/server/web/app/common/views/components/messaging.vue similarity index 100% rename from src/web/app/common/views/components/messaging.vue rename to src/server/web/app/common/views/components/messaging.vue diff --git a/src/web/app/common/views/components/nav.vue b/src/server/web/app/common/views/components/nav.vue similarity index 100% rename from src/web/app/common/views/components/nav.vue rename to src/server/web/app/common/views/components/nav.vue diff --git a/src/web/app/common/views/components/othello.game.vue b/src/server/web/app/common/views/components/othello.game.vue similarity index 100% rename from src/web/app/common/views/components/othello.game.vue rename to src/server/web/app/common/views/components/othello.game.vue diff --git a/src/web/app/common/views/components/othello.gameroom.vue b/src/server/web/app/common/views/components/othello.gameroom.vue similarity index 100% rename from src/web/app/common/views/components/othello.gameroom.vue rename to src/server/web/app/common/views/components/othello.gameroom.vue diff --git a/src/web/app/common/views/components/othello.room.vue b/src/server/web/app/common/views/components/othello.room.vue similarity index 100% rename from src/web/app/common/views/components/othello.room.vue rename to src/server/web/app/common/views/components/othello.room.vue diff --git a/src/web/app/common/views/components/othello.vue b/src/server/web/app/common/views/components/othello.vue similarity index 100% rename from src/web/app/common/views/components/othello.vue rename to src/server/web/app/common/views/components/othello.vue diff --git a/src/web/app/common/views/components/poll-editor.vue b/src/server/web/app/common/views/components/poll-editor.vue similarity index 100% rename from src/web/app/common/views/components/poll-editor.vue rename to src/server/web/app/common/views/components/poll-editor.vue diff --git a/src/web/app/common/views/components/poll.vue b/src/server/web/app/common/views/components/poll.vue similarity index 100% rename from src/web/app/common/views/components/poll.vue rename to src/server/web/app/common/views/components/poll.vue diff --git a/src/web/app/common/views/components/post-html.ts b/src/server/web/app/common/views/components/post-html.ts similarity index 100% rename from src/web/app/common/views/components/post-html.ts rename to src/server/web/app/common/views/components/post-html.ts diff --git a/src/web/app/common/views/components/post-menu.vue b/src/server/web/app/common/views/components/post-menu.vue similarity index 100% rename from src/web/app/common/views/components/post-menu.vue rename to src/server/web/app/common/views/components/post-menu.vue diff --git a/src/web/app/common/views/components/reaction-icon.vue b/src/server/web/app/common/views/components/reaction-icon.vue similarity index 100% rename from src/web/app/common/views/components/reaction-icon.vue rename to src/server/web/app/common/views/components/reaction-icon.vue diff --git a/src/web/app/common/views/components/reaction-picker.vue b/src/server/web/app/common/views/components/reaction-picker.vue similarity index 100% rename from src/web/app/common/views/components/reaction-picker.vue rename to src/server/web/app/common/views/components/reaction-picker.vue diff --git a/src/web/app/common/views/components/reactions-viewer.vue b/src/server/web/app/common/views/components/reactions-viewer.vue similarity index 100% rename from src/web/app/common/views/components/reactions-viewer.vue rename to src/server/web/app/common/views/components/reactions-viewer.vue diff --git a/src/web/app/common/views/components/signin.vue b/src/server/web/app/common/views/components/signin.vue similarity index 100% rename from src/web/app/common/views/components/signin.vue rename to src/server/web/app/common/views/components/signin.vue diff --git a/src/web/app/common/views/components/signup.vue b/src/server/web/app/common/views/components/signup.vue similarity index 100% rename from src/web/app/common/views/components/signup.vue rename to src/server/web/app/common/views/components/signup.vue diff --git a/src/web/app/common/views/components/special-message.vue b/src/server/web/app/common/views/components/special-message.vue similarity index 100% rename from src/web/app/common/views/components/special-message.vue rename to src/server/web/app/common/views/components/special-message.vue diff --git a/src/web/app/common/views/components/stream-indicator.vue b/src/server/web/app/common/views/components/stream-indicator.vue similarity index 100% rename from src/web/app/common/views/components/stream-indicator.vue rename to src/server/web/app/common/views/components/stream-indicator.vue diff --git a/src/web/app/common/views/components/switch.vue b/src/server/web/app/common/views/components/switch.vue similarity index 100% rename from src/web/app/common/views/components/switch.vue rename to src/server/web/app/common/views/components/switch.vue diff --git a/src/web/app/common/views/components/time.vue b/src/server/web/app/common/views/components/time.vue similarity index 100% rename from src/web/app/common/views/components/time.vue rename to src/server/web/app/common/views/components/time.vue diff --git a/src/web/app/common/views/components/timer.vue b/src/server/web/app/common/views/components/timer.vue similarity index 100% rename from src/web/app/common/views/components/timer.vue rename to src/server/web/app/common/views/components/timer.vue diff --git a/src/web/app/common/views/components/twitter-setting.vue b/src/server/web/app/common/views/components/twitter-setting.vue similarity index 100% rename from src/web/app/common/views/components/twitter-setting.vue rename to src/server/web/app/common/views/components/twitter-setting.vue diff --git a/src/web/app/common/views/components/uploader.vue b/src/server/web/app/common/views/components/uploader.vue similarity index 100% rename from src/web/app/common/views/components/uploader.vue rename to src/server/web/app/common/views/components/uploader.vue diff --git a/src/web/app/common/views/components/url-preview.vue b/src/server/web/app/common/views/components/url-preview.vue similarity index 100% rename from src/web/app/common/views/components/url-preview.vue rename to src/server/web/app/common/views/components/url-preview.vue diff --git a/src/web/app/common/views/components/url.vue b/src/server/web/app/common/views/components/url.vue similarity index 100% rename from src/web/app/common/views/components/url.vue rename to src/server/web/app/common/views/components/url.vue diff --git a/src/web/app/common/views/components/welcome-timeline.vue b/src/server/web/app/common/views/components/welcome-timeline.vue similarity index 100% rename from src/web/app/common/views/components/welcome-timeline.vue rename to src/server/web/app/common/views/components/welcome-timeline.vue diff --git a/src/web/app/common/views/directives/autocomplete.ts b/src/server/web/app/common/views/directives/autocomplete.ts similarity index 100% rename from src/web/app/common/views/directives/autocomplete.ts rename to src/server/web/app/common/views/directives/autocomplete.ts diff --git a/src/web/app/common/views/directives/index.ts b/src/server/web/app/common/views/directives/index.ts similarity index 100% rename from src/web/app/common/views/directives/index.ts rename to src/server/web/app/common/views/directives/index.ts diff --git a/src/web/app/common/views/filters/bytes.ts b/src/server/web/app/common/views/filters/bytes.ts similarity index 100% rename from src/web/app/common/views/filters/bytes.ts rename to src/server/web/app/common/views/filters/bytes.ts diff --git a/src/web/app/common/views/filters/index.ts b/src/server/web/app/common/views/filters/index.ts similarity index 100% rename from src/web/app/common/views/filters/index.ts rename to src/server/web/app/common/views/filters/index.ts diff --git a/src/web/app/common/views/filters/number.ts b/src/server/web/app/common/views/filters/number.ts similarity index 100% rename from src/web/app/common/views/filters/number.ts rename to src/server/web/app/common/views/filters/number.ts diff --git a/src/web/app/common/views/widgets/access-log.vue b/src/server/web/app/common/views/widgets/access-log.vue similarity index 100% rename from src/web/app/common/views/widgets/access-log.vue rename to src/server/web/app/common/views/widgets/access-log.vue diff --git a/src/web/app/common/views/widgets/broadcast.vue b/src/server/web/app/common/views/widgets/broadcast.vue similarity index 100% rename from src/web/app/common/views/widgets/broadcast.vue rename to src/server/web/app/common/views/widgets/broadcast.vue diff --git a/src/web/app/common/views/widgets/calendar.vue b/src/server/web/app/common/views/widgets/calendar.vue similarity index 100% rename from src/web/app/common/views/widgets/calendar.vue rename to src/server/web/app/common/views/widgets/calendar.vue diff --git a/src/web/app/common/views/widgets/donation.vue b/src/server/web/app/common/views/widgets/donation.vue similarity index 100% rename from src/web/app/common/views/widgets/donation.vue rename to src/server/web/app/common/views/widgets/donation.vue diff --git a/src/web/app/common/views/widgets/index.ts b/src/server/web/app/common/views/widgets/index.ts similarity index 100% rename from src/web/app/common/views/widgets/index.ts rename to src/server/web/app/common/views/widgets/index.ts diff --git a/src/web/app/common/views/widgets/nav.vue b/src/server/web/app/common/views/widgets/nav.vue similarity index 100% rename from src/web/app/common/views/widgets/nav.vue rename to src/server/web/app/common/views/widgets/nav.vue diff --git a/src/web/app/common/views/widgets/photo-stream.vue b/src/server/web/app/common/views/widgets/photo-stream.vue similarity index 100% rename from src/web/app/common/views/widgets/photo-stream.vue rename to src/server/web/app/common/views/widgets/photo-stream.vue diff --git a/src/web/app/common/views/widgets/rss.vue b/src/server/web/app/common/views/widgets/rss.vue similarity index 100% rename from src/web/app/common/views/widgets/rss.vue rename to src/server/web/app/common/views/widgets/rss.vue diff --git a/src/web/app/common/views/widgets/server.cpu-memory.vue b/src/server/web/app/common/views/widgets/server.cpu-memory.vue similarity index 100% rename from src/web/app/common/views/widgets/server.cpu-memory.vue rename to src/server/web/app/common/views/widgets/server.cpu-memory.vue diff --git a/src/web/app/common/views/widgets/server.cpu.vue b/src/server/web/app/common/views/widgets/server.cpu.vue similarity index 100% rename from src/web/app/common/views/widgets/server.cpu.vue rename to src/server/web/app/common/views/widgets/server.cpu.vue diff --git a/src/web/app/common/views/widgets/server.disk.vue b/src/server/web/app/common/views/widgets/server.disk.vue similarity index 100% rename from src/web/app/common/views/widgets/server.disk.vue rename to src/server/web/app/common/views/widgets/server.disk.vue diff --git a/src/web/app/common/views/widgets/server.info.vue b/src/server/web/app/common/views/widgets/server.info.vue similarity index 100% rename from src/web/app/common/views/widgets/server.info.vue rename to src/server/web/app/common/views/widgets/server.info.vue diff --git a/src/web/app/common/views/widgets/server.memory.vue b/src/server/web/app/common/views/widgets/server.memory.vue similarity index 100% rename from src/web/app/common/views/widgets/server.memory.vue rename to src/server/web/app/common/views/widgets/server.memory.vue diff --git a/src/web/app/common/views/widgets/server.pie.vue b/src/server/web/app/common/views/widgets/server.pie.vue similarity index 100% rename from src/web/app/common/views/widgets/server.pie.vue rename to src/server/web/app/common/views/widgets/server.pie.vue diff --git a/src/web/app/common/views/widgets/server.uptimes.vue b/src/server/web/app/common/views/widgets/server.uptimes.vue similarity index 100% rename from src/web/app/common/views/widgets/server.uptimes.vue rename to src/server/web/app/common/views/widgets/server.uptimes.vue diff --git a/src/web/app/common/views/widgets/server.vue b/src/server/web/app/common/views/widgets/server.vue similarity index 100% rename from src/web/app/common/views/widgets/server.vue rename to src/server/web/app/common/views/widgets/server.vue diff --git a/src/web/app/common/views/widgets/slideshow.vue b/src/server/web/app/common/views/widgets/slideshow.vue similarity index 100% rename from src/web/app/common/views/widgets/slideshow.vue rename to src/server/web/app/common/views/widgets/slideshow.vue diff --git a/src/web/app/common/views/widgets/tips.vue b/src/server/web/app/common/views/widgets/tips.vue similarity index 100% rename from src/web/app/common/views/widgets/tips.vue rename to src/server/web/app/common/views/widgets/tips.vue diff --git a/src/web/app/common/views/widgets/version.vue b/src/server/web/app/common/views/widgets/version.vue similarity index 100% rename from src/web/app/common/views/widgets/version.vue rename to src/server/web/app/common/views/widgets/version.vue diff --git a/src/web/app/config.ts b/src/server/web/app/config.ts similarity index 100% rename from src/web/app/config.ts rename to src/server/web/app/config.ts diff --git a/src/web/app/desktop/api/choose-drive-file.ts b/src/server/web/app/desktop/api/choose-drive-file.ts similarity index 100% rename from src/web/app/desktop/api/choose-drive-file.ts rename to src/server/web/app/desktop/api/choose-drive-file.ts diff --git a/src/web/app/desktop/api/choose-drive-folder.ts b/src/server/web/app/desktop/api/choose-drive-folder.ts similarity index 100% rename from src/web/app/desktop/api/choose-drive-folder.ts rename to src/server/web/app/desktop/api/choose-drive-folder.ts diff --git a/src/web/app/desktop/api/contextmenu.ts b/src/server/web/app/desktop/api/contextmenu.ts similarity index 100% rename from src/web/app/desktop/api/contextmenu.ts rename to src/server/web/app/desktop/api/contextmenu.ts diff --git a/src/web/app/desktop/api/dialog.ts b/src/server/web/app/desktop/api/dialog.ts similarity index 100% rename from src/web/app/desktop/api/dialog.ts rename to src/server/web/app/desktop/api/dialog.ts diff --git a/src/web/app/desktop/api/input.ts b/src/server/web/app/desktop/api/input.ts similarity index 100% rename from src/web/app/desktop/api/input.ts rename to src/server/web/app/desktop/api/input.ts diff --git a/src/web/app/desktop/api/notify.ts b/src/server/web/app/desktop/api/notify.ts similarity index 100% rename from src/web/app/desktop/api/notify.ts rename to src/server/web/app/desktop/api/notify.ts diff --git a/src/web/app/desktop/api/post.ts b/src/server/web/app/desktop/api/post.ts similarity index 100% rename from src/web/app/desktop/api/post.ts rename to src/server/web/app/desktop/api/post.ts diff --git a/src/web/app/desktop/api/update-avatar.ts b/src/server/web/app/desktop/api/update-avatar.ts similarity index 100% rename from src/web/app/desktop/api/update-avatar.ts rename to src/server/web/app/desktop/api/update-avatar.ts diff --git a/src/web/app/desktop/api/update-banner.ts b/src/server/web/app/desktop/api/update-banner.ts similarity index 100% rename from src/web/app/desktop/api/update-banner.ts rename to src/server/web/app/desktop/api/update-banner.ts diff --git a/src/web/app/desktop/assets/grid.svg b/src/server/web/app/desktop/assets/grid.svg similarity index 100% rename from src/web/app/desktop/assets/grid.svg rename to src/server/web/app/desktop/assets/grid.svg diff --git a/src/web/app/desktop/assets/header-logo-white.svg b/src/server/web/app/desktop/assets/header-logo-white.svg similarity index 100% rename from src/web/app/desktop/assets/header-logo-white.svg rename to src/server/web/app/desktop/assets/header-logo-white.svg diff --git a/src/web/app/desktop/assets/header-logo.svg b/src/server/web/app/desktop/assets/header-logo.svg similarity index 100% rename from src/web/app/desktop/assets/header-logo.svg rename to src/server/web/app/desktop/assets/header-logo.svg diff --git a/src/web/app/desktop/assets/index.jpg b/src/server/web/app/desktop/assets/index.jpg similarity index 100% rename from src/web/app/desktop/assets/index.jpg rename to src/server/web/app/desktop/assets/index.jpg diff --git a/src/web/app/desktop/assets/remove.png b/src/server/web/app/desktop/assets/remove.png similarity index 100% rename from src/web/app/desktop/assets/remove.png rename to src/server/web/app/desktop/assets/remove.png diff --git a/src/web/app/desktop/script.ts b/src/server/web/app/desktop/script.ts similarity index 100% rename from src/web/app/desktop/script.ts rename to src/server/web/app/desktop/script.ts diff --git a/src/web/app/desktop/style.styl b/src/server/web/app/desktop/style.styl similarity index 100% rename from src/web/app/desktop/style.styl rename to src/server/web/app/desktop/style.styl diff --git a/src/web/app/desktop/ui.styl b/src/server/web/app/desktop/ui.styl similarity index 100% rename from src/web/app/desktop/ui.styl rename to src/server/web/app/desktop/ui.styl diff --git a/src/web/app/desktop/views/components/activity.calendar.vue b/src/server/web/app/desktop/views/components/activity.calendar.vue similarity index 100% rename from src/web/app/desktop/views/components/activity.calendar.vue rename to src/server/web/app/desktop/views/components/activity.calendar.vue diff --git a/src/web/app/desktop/views/components/activity.chart.vue b/src/server/web/app/desktop/views/components/activity.chart.vue similarity index 100% rename from src/web/app/desktop/views/components/activity.chart.vue rename to src/server/web/app/desktop/views/components/activity.chart.vue diff --git a/src/web/app/desktop/views/components/activity.vue b/src/server/web/app/desktop/views/components/activity.vue similarity index 100% rename from src/web/app/desktop/views/components/activity.vue rename to src/server/web/app/desktop/views/components/activity.vue diff --git a/src/web/app/desktop/views/components/analog-clock.vue b/src/server/web/app/desktop/views/components/analog-clock.vue similarity index 100% rename from src/web/app/desktop/views/components/analog-clock.vue rename to src/server/web/app/desktop/views/components/analog-clock.vue diff --git a/src/web/app/desktop/views/components/calendar.vue b/src/server/web/app/desktop/views/components/calendar.vue similarity index 100% rename from src/web/app/desktop/views/components/calendar.vue rename to src/server/web/app/desktop/views/components/calendar.vue diff --git a/src/web/app/desktop/views/components/choose-file-from-drive-window.vue b/src/server/web/app/desktop/views/components/choose-file-from-drive-window.vue similarity index 100% rename from src/web/app/desktop/views/components/choose-file-from-drive-window.vue rename to src/server/web/app/desktop/views/components/choose-file-from-drive-window.vue diff --git a/src/web/app/desktop/views/components/choose-folder-from-drive-window.vue b/src/server/web/app/desktop/views/components/choose-folder-from-drive-window.vue similarity index 100% rename from src/web/app/desktop/views/components/choose-folder-from-drive-window.vue rename to src/server/web/app/desktop/views/components/choose-folder-from-drive-window.vue diff --git a/src/web/app/desktop/views/components/context-menu.menu.vue b/src/server/web/app/desktop/views/components/context-menu.menu.vue similarity index 100% rename from src/web/app/desktop/views/components/context-menu.menu.vue rename to src/server/web/app/desktop/views/components/context-menu.menu.vue diff --git a/src/web/app/desktop/views/components/context-menu.vue b/src/server/web/app/desktop/views/components/context-menu.vue similarity index 100% rename from src/web/app/desktop/views/components/context-menu.vue rename to src/server/web/app/desktop/views/components/context-menu.vue diff --git a/src/web/app/desktop/views/components/crop-window.vue b/src/server/web/app/desktop/views/components/crop-window.vue similarity index 100% rename from src/web/app/desktop/views/components/crop-window.vue rename to src/server/web/app/desktop/views/components/crop-window.vue diff --git a/src/web/app/desktop/views/components/dialog.vue b/src/server/web/app/desktop/views/components/dialog.vue similarity index 100% rename from src/web/app/desktop/views/components/dialog.vue rename to src/server/web/app/desktop/views/components/dialog.vue diff --git a/src/web/app/desktop/views/components/drive-window.vue b/src/server/web/app/desktop/views/components/drive-window.vue similarity index 100% rename from src/web/app/desktop/views/components/drive-window.vue rename to src/server/web/app/desktop/views/components/drive-window.vue diff --git a/src/web/app/desktop/views/components/drive.file.vue b/src/server/web/app/desktop/views/components/drive.file.vue similarity index 100% rename from src/web/app/desktop/views/components/drive.file.vue rename to src/server/web/app/desktop/views/components/drive.file.vue diff --git a/src/web/app/desktop/views/components/drive.folder.vue b/src/server/web/app/desktop/views/components/drive.folder.vue similarity index 100% rename from src/web/app/desktop/views/components/drive.folder.vue rename to src/server/web/app/desktop/views/components/drive.folder.vue diff --git a/src/web/app/desktop/views/components/drive.nav-folder.vue b/src/server/web/app/desktop/views/components/drive.nav-folder.vue similarity index 100% rename from src/web/app/desktop/views/components/drive.nav-folder.vue rename to src/server/web/app/desktop/views/components/drive.nav-folder.vue diff --git a/src/web/app/desktop/views/components/drive.vue b/src/server/web/app/desktop/views/components/drive.vue similarity index 100% rename from src/web/app/desktop/views/components/drive.vue rename to src/server/web/app/desktop/views/components/drive.vue diff --git a/src/web/app/desktop/views/components/ellipsis-icon.vue b/src/server/web/app/desktop/views/components/ellipsis-icon.vue similarity index 100% rename from src/web/app/desktop/views/components/ellipsis-icon.vue rename to src/server/web/app/desktop/views/components/ellipsis-icon.vue diff --git a/src/web/app/desktop/views/components/follow-button.vue b/src/server/web/app/desktop/views/components/follow-button.vue similarity index 100% rename from src/web/app/desktop/views/components/follow-button.vue rename to src/server/web/app/desktop/views/components/follow-button.vue diff --git a/src/web/app/desktop/views/components/followers-window.vue b/src/server/web/app/desktop/views/components/followers-window.vue similarity index 100% rename from src/web/app/desktop/views/components/followers-window.vue rename to src/server/web/app/desktop/views/components/followers-window.vue diff --git a/src/web/app/desktop/views/components/followers.vue b/src/server/web/app/desktop/views/components/followers.vue similarity index 100% rename from src/web/app/desktop/views/components/followers.vue rename to src/server/web/app/desktop/views/components/followers.vue diff --git a/src/web/app/desktop/views/components/following-window.vue b/src/server/web/app/desktop/views/components/following-window.vue similarity index 100% rename from src/web/app/desktop/views/components/following-window.vue rename to src/server/web/app/desktop/views/components/following-window.vue diff --git a/src/web/app/desktop/views/components/following.vue b/src/server/web/app/desktop/views/components/following.vue similarity index 100% rename from src/web/app/desktop/views/components/following.vue rename to src/server/web/app/desktop/views/components/following.vue diff --git a/src/web/app/desktop/views/components/friends-maker.vue b/src/server/web/app/desktop/views/components/friends-maker.vue similarity index 100% rename from src/web/app/desktop/views/components/friends-maker.vue rename to src/server/web/app/desktop/views/components/friends-maker.vue diff --git a/src/web/app/desktop/views/components/game-window.vue b/src/server/web/app/desktop/views/components/game-window.vue similarity index 100% rename from src/web/app/desktop/views/components/game-window.vue rename to src/server/web/app/desktop/views/components/game-window.vue diff --git a/src/web/app/desktop/views/components/home.vue b/src/server/web/app/desktop/views/components/home.vue similarity index 100% rename from src/web/app/desktop/views/components/home.vue rename to src/server/web/app/desktop/views/components/home.vue diff --git a/src/web/app/desktop/views/components/index.ts b/src/server/web/app/desktop/views/components/index.ts similarity index 100% rename from src/web/app/desktop/views/components/index.ts rename to src/server/web/app/desktop/views/components/index.ts diff --git a/src/web/app/desktop/views/components/input-dialog.vue b/src/server/web/app/desktop/views/components/input-dialog.vue similarity index 100% rename from src/web/app/desktop/views/components/input-dialog.vue rename to src/server/web/app/desktop/views/components/input-dialog.vue diff --git a/src/web/app/desktop/views/components/media-image-dialog.vue b/src/server/web/app/desktop/views/components/media-image-dialog.vue similarity index 100% rename from src/web/app/desktop/views/components/media-image-dialog.vue rename to src/server/web/app/desktop/views/components/media-image-dialog.vue diff --git a/src/web/app/desktop/views/components/media-image.vue b/src/server/web/app/desktop/views/components/media-image.vue similarity index 100% rename from src/web/app/desktop/views/components/media-image.vue rename to src/server/web/app/desktop/views/components/media-image.vue diff --git a/src/web/app/desktop/views/components/media-video-dialog.vue b/src/server/web/app/desktop/views/components/media-video-dialog.vue similarity index 100% rename from src/web/app/desktop/views/components/media-video-dialog.vue rename to src/server/web/app/desktop/views/components/media-video-dialog.vue diff --git a/src/web/app/desktop/views/components/media-video.vue b/src/server/web/app/desktop/views/components/media-video.vue similarity index 100% rename from src/web/app/desktop/views/components/media-video.vue rename to src/server/web/app/desktop/views/components/media-video.vue diff --git a/src/web/app/desktop/views/components/mentions.vue b/src/server/web/app/desktop/views/components/mentions.vue similarity index 100% rename from src/web/app/desktop/views/components/mentions.vue rename to src/server/web/app/desktop/views/components/mentions.vue diff --git a/src/web/app/desktop/views/components/messaging-room-window.vue b/src/server/web/app/desktop/views/components/messaging-room-window.vue similarity index 100% rename from src/web/app/desktop/views/components/messaging-room-window.vue rename to src/server/web/app/desktop/views/components/messaging-room-window.vue diff --git a/src/web/app/desktop/views/components/messaging-window.vue b/src/server/web/app/desktop/views/components/messaging-window.vue similarity index 100% rename from src/web/app/desktop/views/components/messaging-window.vue rename to src/server/web/app/desktop/views/components/messaging-window.vue diff --git a/src/web/app/desktop/views/components/notifications.vue b/src/server/web/app/desktop/views/components/notifications.vue similarity index 100% rename from src/web/app/desktop/views/components/notifications.vue rename to src/server/web/app/desktop/views/components/notifications.vue diff --git a/src/web/app/desktop/views/components/post-detail.sub.vue b/src/server/web/app/desktop/views/components/post-detail.sub.vue similarity index 100% rename from src/web/app/desktop/views/components/post-detail.sub.vue rename to src/server/web/app/desktop/views/components/post-detail.sub.vue diff --git a/src/web/app/desktop/views/components/post-detail.vue b/src/server/web/app/desktop/views/components/post-detail.vue similarity index 100% rename from src/web/app/desktop/views/components/post-detail.vue rename to src/server/web/app/desktop/views/components/post-detail.vue diff --git a/src/web/app/desktop/views/components/post-form-window.vue b/src/server/web/app/desktop/views/components/post-form-window.vue similarity index 100% rename from src/web/app/desktop/views/components/post-form-window.vue rename to src/server/web/app/desktop/views/components/post-form-window.vue diff --git a/src/web/app/desktop/views/components/post-form.vue b/src/server/web/app/desktop/views/components/post-form.vue similarity index 100% rename from src/web/app/desktop/views/components/post-form.vue rename to src/server/web/app/desktop/views/components/post-form.vue diff --git a/src/web/app/desktop/views/components/post-preview.vue b/src/server/web/app/desktop/views/components/post-preview.vue similarity index 100% rename from src/web/app/desktop/views/components/post-preview.vue rename to src/server/web/app/desktop/views/components/post-preview.vue diff --git a/src/web/app/desktop/views/components/posts.post.sub.vue b/src/server/web/app/desktop/views/components/posts.post.sub.vue similarity index 100% rename from src/web/app/desktop/views/components/posts.post.sub.vue rename to src/server/web/app/desktop/views/components/posts.post.sub.vue diff --git a/src/web/app/desktop/views/components/posts.post.vue b/src/server/web/app/desktop/views/components/posts.post.vue similarity index 100% rename from src/web/app/desktop/views/components/posts.post.vue rename to src/server/web/app/desktop/views/components/posts.post.vue diff --git a/src/web/app/desktop/views/components/posts.vue b/src/server/web/app/desktop/views/components/posts.vue similarity index 100% rename from src/web/app/desktop/views/components/posts.vue rename to src/server/web/app/desktop/views/components/posts.vue diff --git a/src/web/app/desktop/views/components/progress-dialog.vue b/src/server/web/app/desktop/views/components/progress-dialog.vue similarity index 100% rename from src/web/app/desktop/views/components/progress-dialog.vue rename to src/server/web/app/desktop/views/components/progress-dialog.vue diff --git a/src/web/app/desktop/views/components/repost-form-window.vue b/src/server/web/app/desktop/views/components/repost-form-window.vue similarity index 100% rename from src/web/app/desktop/views/components/repost-form-window.vue rename to src/server/web/app/desktop/views/components/repost-form-window.vue diff --git a/src/web/app/desktop/views/components/repost-form.vue b/src/server/web/app/desktop/views/components/repost-form.vue similarity index 100% rename from src/web/app/desktop/views/components/repost-form.vue rename to src/server/web/app/desktop/views/components/repost-form.vue diff --git a/src/web/app/desktop/views/components/settings-window.vue b/src/server/web/app/desktop/views/components/settings-window.vue similarity index 100% rename from src/web/app/desktop/views/components/settings-window.vue rename to src/server/web/app/desktop/views/components/settings-window.vue diff --git a/src/web/app/desktop/views/components/settings.2fa.vue b/src/server/web/app/desktop/views/components/settings.2fa.vue similarity index 100% rename from src/web/app/desktop/views/components/settings.2fa.vue rename to src/server/web/app/desktop/views/components/settings.2fa.vue diff --git a/src/web/app/desktop/views/components/settings.api.vue b/src/server/web/app/desktop/views/components/settings.api.vue similarity index 100% rename from src/web/app/desktop/views/components/settings.api.vue rename to src/server/web/app/desktop/views/components/settings.api.vue diff --git a/src/web/app/desktop/views/components/settings.apps.vue b/src/server/web/app/desktop/views/components/settings.apps.vue similarity index 100% rename from src/web/app/desktop/views/components/settings.apps.vue rename to src/server/web/app/desktop/views/components/settings.apps.vue diff --git a/src/web/app/desktop/views/components/settings.drive.vue b/src/server/web/app/desktop/views/components/settings.drive.vue similarity index 100% rename from src/web/app/desktop/views/components/settings.drive.vue rename to src/server/web/app/desktop/views/components/settings.drive.vue diff --git a/src/web/app/desktop/views/components/settings.mute.vue b/src/server/web/app/desktop/views/components/settings.mute.vue similarity index 100% rename from src/web/app/desktop/views/components/settings.mute.vue rename to src/server/web/app/desktop/views/components/settings.mute.vue diff --git a/src/web/app/desktop/views/components/settings.password.vue b/src/server/web/app/desktop/views/components/settings.password.vue similarity index 100% rename from src/web/app/desktop/views/components/settings.password.vue rename to src/server/web/app/desktop/views/components/settings.password.vue diff --git a/src/web/app/desktop/views/components/settings.profile.vue b/src/server/web/app/desktop/views/components/settings.profile.vue similarity index 100% rename from src/web/app/desktop/views/components/settings.profile.vue rename to src/server/web/app/desktop/views/components/settings.profile.vue diff --git a/src/web/app/desktop/views/components/settings.signins.vue b/src/server/web/app/desktop/views/components/settings.signins.vue similarity index 100% rename from src/web/app/desktop/views/components/settings.signins.vue rename to src/server/web/app/desktop/views/components/settings.signins.vue diff --git a/src/web/app/desktop/views/components/settings.vue b/src/server/web/app/desktop/views/components/settings.vue similarity index 100% rename from src/web/app/desktop/views/components/settings.vue rename to src/server/web/app/desktop/views/components/settings.vue diff --git a/src/web/app/desktop/views/components/sub-post-content.vue b/src/server/web/app/desktop/views/components/sub-post-content.vue similarity index 100% rename from src/web/app/desktop/views/components/sub-post-content.vue rename to src/server/web/app/desktop/views/components/sub-post-content.vue diff --git a/src/web/app/desktop/views/components/taskmanager.vue b/src/server/web/app/desktop/views/components/taskmanager.vue similarity index 100% rename from src/web/app/desktop/views/components/taskmanager.vue rename to src/server/web/app/desktop/views/components/taskmanager.vue diff --git a/src/web/app/desktop/views/components/timeline.vue b/src/server/web/app/desktop/views/components/timeline.vue similarity index 100% rename from src/web/app/desktop/views/components/timeline.vue rename to src/server/web/app/desktop/views/components/timeline.vue diff --git a/src/web/app/desktop/views/components/ui-notification.vue b/src/server/web/app/desktop/views/components/ui-notification.vue similarity index 100% rename from src/web/app/desktop/views/components/ui-notification.vue rename to src/server/web/app/desktop/views/components/ui-notification.vue diff --git a/src/web/app/desktop/views/components/ui.header.account.vue b/src/server/web/app/desktop/views/components/ui.header.account.vue similarity index 100% rename from src/web/app/desktop/views/components/ui.header.account.vue rename to src/server/web/app/desktop/views/components/ui.header.account.vue diff --git a/src/web/app/desktop/views/components/ui.header.clock.vue b/src/server/web/app/desktop/views/components/ui.header.clock.vue similarity index 100% rename from src/web/app/desktop/views/components/ui.header.clock.vue rename to src/server/web/app/desktop/views/components/ui.header.clock.vue diff --git a/src/web/app/desktop/views/components/ui.header.nav.vue b/src/server/web/app/desktop/views/components/ui.header.nav.vue similarity index 100% rename from src/web/app/desktop/views/components/ui.header.nav.vue rename to src/server/web/app/desktop/views/components/ui.header.nav.vue diff --git a/src/web/app/desktop/views/components/ui.header.notifications.vue b/src/server/web/app/desktop/views/components/ui.header.notifications.vue similarity index 100% rename from src/web/app/desktop/views/components/ui.header.notifications.vue rename to src/server/web/app/desktop/views/components/ui.header.notifications.vue diff --git a/src/web/app/desktop/views/components/ui.header.post.vue b/src/server/web/app/desktop/views/components/ui.header.post.vue similarity index 100% rename from src/web/app/desktop/views/components/ui.header.post.vue rename to src/server/web/app/desktop/views/components/ui.header.post.vue diff --git a/src/web/app/desktop/views/components/ui.header.search.vue b/src/server/web/app/desktop/views/components/ui.header.search.vue similarity index 100% rename from src/web/app/desktop/views/components/ui.header.search.vue rename to src/server/web/app/desktop/views/components/ui.header.search.vue diff --git a/src/web/app/desktop/views/components/ui.header.vue b/src/server/web/app/desktop/views/components/ui.header.vue similarity index 100% rename from src/web/app/desktop/views/components/ui.header.vue rename to src/server/web/app/desktop/views/components/ui.header.vue diff --git a/src/web/app/desktop/views/components/ui.vue b/src/server/web/app/desktop/views/components/ui.vue similarity index 100% rename from src/web/app/desktop/views/components/ui.vue rename to src/server/web/app/desktop/views/components/ui.vue diff --git a/src/web/app/desktop/views/components/user-preview.vue b/src/server/web/app/desktop/views/components/user-preview.vue similarity index 100% rename from src/web/app/desktop/views/components/user-preview.vue rename to src/server/web/app/desktop/views/components/user-preview.vue diff --git a/src/web/app/desktop/views/components/users-list.item.vue b/src/server/web/app/desktop/views/components/users-list.item.vue similarity index 100% rename from src/web/app/desktop/views/components/users-list.item.vue rename to src/server/web/app/desktop/views/components/users-list.item.vue diff --git a/src/web/app/desktop/views/components/users-list.vue b/src/server/web/app/desktop/views/components/users-list.vue similarity index 100% rename from src/web/app/desktop/views/components/users-list.vue rename to src/server/web/app/desktop/views/components/users-list.vue diff --git a/src/web/app/desktop/views/components/widget-container.vue b/src/server/web/app/desktop/views/components/widget-container.vue similarity index 100% rename from src/web/app/desktop/views/components/widget-container.vue rename to src/server/web/app/desktop/views/components/widget-container.vue diff --git a/src/web/app/desktop/views/components/window.vue b/src/server/web/app/desktop/views/components/window.vue similarity index 100% rename from src/web/app/desktop/views/components/window.vue rename to src/server/web/app/desktop/views/components/window.vue diff --git a/src/web/app/desktop/views/directives/index.ts b/src/server/web/app/desktop/views/directives/index.ts similarity index 100% rename from src/web/app/desktop/views/directives/index.ts rename to src/server/web/app/desktop/views/directives/index.ts diff --git a/src/web/app/desktop/views/directives/user-preview.ts b/src/server/web/app/desktop/views/directives/user-preview.ts similarity index 100% rename from src/web/app/desktop/views/directives/user-preview.ts rename to src/server/web/app/desktop/views/directives/user-preview.ts diff --git a/src/web/app/desktop/views/pages/drive.vue b/src/server/web/app/desktop/views/pages/drive.vue similarity index 100% rename from src/web/app/desktop/views/pages/drive.vue rename to src/server/web/app/desktop/views/pages/drive.vue diff --git a/src/web/app/desktop/views/pages/home-customize.vue b/src/server/web/app/desktop/views/pages/home-customize.vue similarity index 100% rename from src/web/app/desktop/views/pages/home-customize.vue rename to src/server/web/app/desktop/views/pages/home-customize.vue diff --git a/src/web/app/desktop/views/pages/home.vue b/src/server/web/app/desktop/views/pages/home.vue similarity index 100% rename from src/web/app/desktop/views/pages/home.vue rename to src/server/web/app/desktop/views/pages/home.vue diff --git a/src/web/app/desktop/views/pages/index.vue b/src/server/web/app/desktop/views/pages/index.vue similarity index 100% rename from src/web/app/desktop/views/pages/index.vue rename to src/server/web/app/desktop/views/pages/index.vue diff --git a/src/web/app/desktop/views/pages/messaging-room.vue b/src/server/web/app/desktop/views/pages/messaging-room.vue similarity index 100% rename from src/web/app/desktop/views/pages/messaging-room.vue rename to src/server/web/app/desktop/views/pages/messaging-room.vue diff --git a/src/web/app/desktop/views/pages/othello.vue b/src/server/web/app/desktop/views/pages/othello.vue similarity index 100% rename from src/web/app/desktop/views/pages/othello.vue rename to src/server/web/app/desktop/views/pages/othello.vue diff --git a/src/web/app/desktop/views/pages/post.vue b/src/server/web/app/desktop/views/pages/post.vue similarity index 100% rename from src/web/app/desktop/views/pages/post.vue rename to src/server/web/app/desktop/views/pages/post.vue diff --git a/src/web/app/desktop/views/pages/search.vue b/src/server/web/app/desktop/views/pages/search.vue similarity index 100% rename from src/web/app/desktop/views/pages/search.vue rename to src/server/web/app/desktop/views/pages/search.vue diff --git a/src/web/app/desktop/views/pages/selectdrive.vue b/src/server/web/app/desktop/views/pages/selectdrive.vue similarity index 100% rename from src/web/app/desktop/views/pages/selectdrive.vue rename to src/server/web/app/desktop/views/pages/selectdrive.vue diff --git a/src/web/app/desktop/views/pages/user/user.followers-you-know.vue b/src/server/web/app/desktop/views/pages/user/user.followers-you-know.vue similarity index 100% rename from src/web/app/desktop/views/pages/user/user.followers-you-know.vue rename to src/server/web/app/desktop/views/pages/user/user.followers-you-know.vue diff --git a/src/web/app/desktop/views/pages/user/user.friends.vue b/src/server/web/app/desktop/views/pages/user/user.friends.vue similarity index 100% rename from src/web/app/desktop/views/pages/user/user.friends.vue rename to src/server/web/app/desktop/views/pages/user/user.friends.vue diff --git a/src/web/app/desktop/views/pages/user/user.header.vue b/src/server/web/app/desktop/views/pages/user/user.header.vue similarity index 100% rename from src/web/app/desktop/views/pages/user/user.header.vue rename to src/server/web/app/desktop/views/pages/user/user.header.vue diff --git a/src/web/app/desktop/views/pages/user/user.home.vue b/src/server/web/app/desktop/views/pages/user/user.home.vue similarity index 100% rename from src/web/app/desktop/views/pages/user/user.home.vue rename to src/server/web/app/desktop/views/pages/user/user.home.vue diff --git a/src/web/app/desktop/views/pages/user/user.photos.vue b/src/server/web/app/desktop/views/pages/user/user.photos.vue similarity index 100% rename from src/web/app/desktop/views/pages/user/user.photos.vue rename to src/server/web/app/desktop/views/pages/user/user.photos.vue diff --git a/src/web/app/desktop/views/pages/user/user.profile.vue b/src/server/web/app/desktop/views/pages/user/user.profile.vue similarity index 100% rename from src/web/app/desktop/views/pages/user/user.profile.vue rename to src/server/web/app/desktop/views/pages/user/user.profile.vue diff --git a/src/web/app/desktop/views/pages/user/user.timeline.vue b/src/server/web/app/desktop/views/pages/user/user.timeline.vue similarity index 100% rename from src/web/app/desktop/views/pages/user/user.timeline.vue rename to src/server/web/app/desktop/views/pages/user/user.timeline.vue diff --git a/src/web/app/desktop/views/pages/user/user.vue b/src/server/web/app/desktop/views/pages/user/user.vue similarity index 100% rename from src/web/app/desktop/views/pages/user/user.vue rename to src/server/web/app/desktop/views/pages/user/user.vue diff --git a/src/web/app/desktop/views/pages/welcome.vue b/src/server/web/app/desktop/views/pages/welcome.vue similarity index 100% rename from src/web/app/desktop/views/pages/welcome.vue rename to src/server/web/app/desktop/views/pages/welcome.vue diff --git a/src/web/app/desktop/views/widgets/activity.vue b/src/server/web/app/desktop/views/widgets/activity.vue similarity index 100% rename from src/web/app/desktop/views/widgets/activity.vue rename to src/server/web/app/desktop/views/widgets/activity.vue diff --git a/src/web/app/desktop/views/widgets/channel.channel.form.vue b/src/server/web/app/desktop/views/widgets/channel.channel.form.vue similarity index 100% rename from src/web/app/desktop/views/widgets/channel.channel.form.vue rename to src/server/web/app/desktop/views/widgets/channel.channel.form.vue diff --git a/src/web/app/desktop/views/widgets/channel.channel.post.vue b/src/server/web/app/desktop/views/widgets/channel.channel.post.vue similarity index 100% rename from src/web/app/desktop/views/widgets/channel.channel.post.vue rename to src/server/web/app/desktop/views/widgets/channel.channel.post.vue diff --git a/src/web/app/desktop/views/widgets/channel.channel.vue b/src/server/web/app/desktop/views/widgets/channel.channel.vue similarity index 100% rename from src/web/app/desktop/views/widgets/channel.channel.vue rename to src/server/web/app/desktop/views/widgets/channel.channel.vue diff --git a/src/web/app/desktop/views/widgets/channel.vue b/src/server/web/app/desktop/views/widgets/channel.vue similarity index 100% rename from src/web/app/desktop/views/widgets/channel.vue rename to src/server/web/app/desktop/views/widgets/channel.vue diff --git a/src/web/app/desktop/views/widgets/index.ts b/src/server/web/app/desktop/views/widgets/index.ts similarity index 100% rename from src/web/app/desktop/views/widgets/index.ts rename to src/server/web/app/desktop/views/widgets/index.ts diff --git a/src/web/app/desktop/views/widgets/messaging.vue b/src/server/web/app/desktop/views/widgets/messaging.vue similarity index 100% rename from src/web/app/desktop/views/widgets/messaging.vue rename to src/server/web/app/desktop/views/widgets/messaging.vue diff --git a/src/web/app/desktop/views/widgets/notifications.vue b/src/server/web/app/desktop/views/widgets/notifications.vue similarity index 100% rename from src/web/app/desktop/views/widgets/notifications.vue rename to src/server/web/app/desktop/views/widgets/notifications.vue diff --git a/src/web/app/desktop/views/widgets/polls.vue b/src/server/web/app/desktop/views/widgets/polls.vue similarity index 100% rename from src/web/app/desktop/views/widgets/polls.vue rename to src/server/web/app/desktop/views/widgets/polls.vue diff --git a/src/web/app/desktop/views/widgets/post-form.vue b/src/server/web/app/desktop/views/widgets/post-form.vue similarity index 100% rename from src/web/app/desktop/views/widgets/post-form.vue rename to src/server/web/app/desktop/views/widgets/post-form.vue diff --git a/src/web/app/desktop/views/widgets/profile.vue b/src/server/web/app/desktop/views/widgets/profile.vue similarity index 100% rename from src/web/app/desktop/views/widgets/profile.vue rename to src/server/web/app/desktop/views/widgets/profile.vue diff --git a/src/web/app/desktop/views/widgets/timemachine.vue b/src/server/web/app/desktop/views/widgets/timemachine.vue similarity index 100% rename from src/web/app/desktop/views/widgets/timemachine.vue rename to src/server/web/app/desktop/views/widgets/timemachine.vue diff --git a/src/web/app/desktop/views/widgets/trends.vue b/src/server/web/app/desktop/views/widgets/trends.vue similarity index 100% rename from src/web/app/desktop/views/widgets/trends.vue rename to src/server/web/app/desktop/views/widgets/trends.vue diff --git a/src/web/app/desktop/views/widgets/users.vue b/src/server/web/app/desktop/views/widgets/users.vue similarity index 100% rename from src/web/app/desktop/views/widgets/users.vue rename to src/server/web/app/desktop/views/widgets/users.vue diff --git a/src/web/app/dev/script.ts b/src/server/web/app/dev/script.ts similarity index 100% rename from src/web/app/dev/script.ts rename to src/server/web/app/dev/script.ts diff --git a/src/web/app/dev/style.styl b/src/server/web/app/dev/style.styl similarity index 100% rename from src/web/app/dev/style.styl rename to src/server/web/app/dev/style.styl diff --git a/src/web/app/dev/views/app.vue b/src/server/web/app/dev/views/app.vue similarity index 100% rename from src/web/app/dev/views/app.vue rename to src/server/web/app/dev/views/app.vue diff --git a/src/web/app/dev/views/apps.vue b/src/server/web/app/dev/views/apps.vue similarity index 100% rename from src/web/app/dev/views/apps.vue rename to src/server/web/app/dev/views/apps.vue diff --git a/src/web/app/dev/views/index.vue b/src/server/web/app/dev/views/index.vue similarity index 100% rename from src/web/app/dev/views/index.vue rename to src/server/web/app/dev/views/index.vue diff --git a/src/web/app/dev/views/new-app.vue b/src/server/web/app/dev/views/new-app.vue similarity index 100% rename from src/web/app/dev/views/new-app.vue rename to src/server/web/app/dev/views/new-app.vue diff --git a/src/web/app/dev/views/ui.vue b/src/server/web/app/dev/views/ui.vue similarity index 100% rename from src/web/app/dev/views/ui.vue rename to src/server/web/app/dev/views/ui.vue diff --git a/src/web/app/init.css b/src/server/web/app/init.css similarity index 100% rename from src/web/app/init.css rename to src/server/web/app/init.css diff --git a/src/web/app/init.ts b/src/server/web/app/init.ts similarity index 100% rename from src/web/app/init.ts rename to src/server/web/app/init.ts diff --git a/src/web/app/mobile/api/choose-drive-file.ts b/src/server/web/app/mobile/api/choose-drive-file.ts similarity index 100% rename from src/web/app/mobile/api/choose-drive-file.ts rename to src/server/web/app/mobile/api/choose-drive-file.ts diff --git a/src/web/app/mobile/api/choose-drive-folder.ts b/src/server/web/app/mobile/api/choose-drive-folder.ts similarity index 100% rename from src/web/app/mobile/api/choose-drive-folder.ts rename to src/server/web/app/mobile/api/choose-drive-folder.ts diff --git a/src/web/app/mobile/api/dialog.ts b/src/server/web/app/mobile/api/dialog.ts similarity index 100% rename from src/web/app/mobile/api/dialog.ts rename to src/server/web/app/mobile/api/dialog.ts diff --git a/src/web/app/mobile/api/input.ts b/src/server/web/app/mobile/api/input.ts similarity index 100% rename from src/web/app/mobile/api/input.ts rename to src/server/web/app/mobile/api/input.ts diff --git a/src/web/app/mobile/api/notify.ts b/src/server/web/app/mobile/api/notify.ts similarity index 100% rename from src/web/app/mobile/api/notify.ts rename to src/server/web/app/mobile/api/notify.ts diff --git a/src/web/app/mobile/api/post.ts b/src/server/web/app/mobile/api/post.ts similarity index 100% rename from src/web/app/mobile/api/post.ts rename to src/server/web/app/mobile/api/post.ts diff --git a/src/web/app/mobile/script.ts b/src/server/web/app/mobile/script.ts similarity index 100% rename from src/web/app/mobile/script.ts rename to src/server/web/app/mobile/script.ts diff --git a/src/web/app/mobile/style.styl b/src/server/web/app/mobile/style.styl similarity index 100% rename from src/web/app/mobile/style.styl rename to src/server/web/app/mobile/style.styl diff --git a/src/web/app/mobile/views/components/activity.vue b/src/server/web/app/mobile/views/components/activity.vue similarity index 100% rename from src/web/app/mobile/views/components/activity.vue rename to src/server/web/app/mobile/views/components/activity.vue diff --git a/src/web/app/mobile/views/components/drive-file-chooser.vue b/src/server/web/app/mobile/views/components/drive-file-chooser.vue similarity index 100% rename from src/web/app/mobile/views/components/drive-file-chooser.vue rename to src/server/web/app/mobile/views/components/drive-file-chooser.vue diff --git a/src/web/app/mobile/views/components/drive-folder-chooser.vue b/src/server/web/app/mobile/views/components/drive-folder-chooser.vue similarity index 100% rename from src/web/app/mobile/views/components/drive-folder-chooser.vue rename to src/server/web/app/mobile/views/components/drive-folder-chooser.vue diff --git a/src/web/app/mobile/views/components/drive.file-detail.vue b/src/server/web/app/mobile/views/components/drive.file-detail.vue similarity index 100% rename from src/web/app/mobile/views/components/drive.file-detail.vue rename to src/server/web/app/mobile/views/components/drive.file-detail.vue diff --git a/src/web/app/mobile/views/components/drive.file.vue b/src/server/web/app/mobile/views/components/drive.file.vue similarity index 100% rename from src/web/app/mobile/views/components/drive.file.vue rename to src/server/web/app/mobile/views/components/drive.file.vue diff --git a/src/web/app/mobile/views/components/drive.folder.vue b/src/server/web/app/mobile/views/components/drive.folder.vue similarity index 100% rename from src/web/app/mobile/views/components/drive.folder.vue rename to src/server/web/app/mobile/views/components/drive.folder.vue diff --git a/src/web/app/mobile/views/components/drive.vue b/src/server/web/app/mobile/views/components/drive.vue similarity index 100% rename from src/web/app/mobile/views/components/drive.vue rename to src/server/web/app/mobile/views/components/drive.vue diff --git a/src/web/app/mobile/views/components/follow-button.vue b/src/server/web/app/mobile/views/components/follow-button.vue similarity index 100% rename from src/web/app/mobile/views/components/follow-button.vue rename to src/server/web/app/mobile/views/components/follow-button.vue diff --git a/src/web/app/mobile/views/components/friends-maker.vue b/src/server/web/app/mobile/views/components/friends-maker.vue similarity index 100% rename from src/web/app/mobile/views/components/friends-maker.vue rename to src/server/web/app/mobile/views/components/friends-maker.vue diff --git a/src/web/app/mobile/views/components/index.ts b/src/server/web/app/mobile/views/components/index.ts similarity index 100% rename from src/web/app/mobile/views/components/index.ts rename to src/server/web/app/mobile/views/components/index.ts diff --git a/src/web/app/mobile/views/components/media-image.vue b/src/server/web/app/mobile/views/components/media-image.vue similarity index 100% rename from src/web/app/mobile/views/components/media-image.vue rename to src/server/web/app/mobile/views/components/media-image.vue diff --git a/src/web/app/mobile/views/components/media-video.vue b/src/server/web/app/mobile/views/components/media-video.vue similarity index 100% rename from src/web/app/mobile/views/components/media-video.vue rename to src/server/web/app/mobile/views/components/media-video.vue diff --git a/src/web/app/mobile/views/components/notification-preview.vue b/src/server/web/app/mobile/views/components/notification-preview.vue similarity index 100% rename from src/web/app/mobile/views/components/notification-preview.vue rename to src/server/web/app/mobile/views/components/notification-preview.vue diff --git a/src/web/app/mobile/views/components/notification.vue b/src/server/web/app/mobile/views/components/notification.vue similarity index 100% rename from src/web/app/mobile/views/components/notification.vue rename to src/server/web/app/mobile/views/components/notification.vue diff --git a/src/web/app/mobile/views/components/notifications.vue b/src/server/web/app/mobile/views/components/notifications.vue similarity index 100% rename from src/web/app/mobile/views/components/notifications.vue rename to src/server/web/app/mobile/views/components/notifications.vue diff --git a/src/web/app/mobile/views/components/notify.vue b/src/server/web/app/mobile/views/components/notify.vue similarity index 100% rename from src/web/app/mobile/views/components/notify.vue rename to src/server/web/app/mobile/views/components/notify.vue diff --git a/src/web/app/mobile/views/components/post-card.vue b/src/server/web/app/mobile/views/components/post-card.vue similarity index 100% rename from src/web/app/mobile/views/components/post-card.vue rename to src/server/web/app/mobile/views/components/post-card.vue diff --git a/src/web/app/mobile/views/components/post-detail.sub.vue b/src/server/web/app/mobile/views/components/post-detail.sub.vue similarity index 100% rename from src/web/app/mobile/views/components/post-detail.sub.vue rename to src/server/web/app/mobile/views/components/post-detail.sub.vue diff --git a/src/web/app/mobile/views/components/post-detail.vue b/src/server/web/app/mobile/views/components/post-detail.vue similarity index 100% rename from src/web/app/mobile/views/components/post-detail.vue rename to src/server/web/app/mobile/views/components/post-detail.vue diff --git a/src/web/app/mobile/views/components/post-form.vue b/src/server/web/app/mobile/views/components/post-form.vue similarity index 100% rename from src/web/app/mobile/views/components/post-form.vue rename to src/server/web/app/mobile/views/components/post-form.vue diff --git a/src/web/app/mobile/views/components/post-preview.vue b/src/server/web/app/mobile/views/components/post-preview.vue similarity index 100% rename from src/web/app/mobile/views/components/post-preview.vue rename to src/server/web/app/mobile/views/components/post-preview.vue diff --git a/src/web/app/mobile/views/components/post.sub.vue b/src/server/web/app/mobile/views/components/post.sub.vue similarity index 100% rename from src/web/app/mobile/views/components/post.sub.vue rename to src/server/web/app/mobile/views/components/post.sub.vue diff --git a/src/web/app/mobile/views/components/post.vue b/src/server/web/app/mobile/views/components/post.vue similarity index 100% rename from src/web/app/mobile/views/components/post.vue rename to src/server/web/app/mobile/views/components/post.vue diff --git a/src/web/app/mobile/views/components/posts.vue b/src/server/web/app/mobile/views/components/posts.vue similarity index 100% rename from src/web/app/mobile/views/components/posts.vue rename to src/server/web/app/mobile/views/components/posts.vue diff --git a/src/web/app/mobile/views/components/sub-post-content.vue b/src/server/web/app/mobile/views/components/sub-post-content.vue similarity index 100% rename from src/web/app/mobile/views/components/sub-post-content.vue rename to src/server/web/app/mobile/views/components/sub-post-content.vue diff --git a/src/web/app/mobile/views/components/timeline.vue b/src/server/web/app/mobile/views/components/timeline.vue similarity index 100% rename from src/web/app/mobile/views/components/timeline.vue rename to src/server/web/app/mobile/views/components/timeline.vue diff --git a/src/web/app/mobile/views/components/ui.header.vue b/src/server/web/app/mobile/views/components/ui.header.vue similarity index 100% rename from src/web/app/mobile/views/components/ui.header.vue rename to src/server/web/app/mobile/views/components/ui.header.vue diff --git a/src/web/app/mobile/views/components/ui.nav.vue b/src/server/web/app/mobile/views/components/ui.nav.vue similarity index 100% rename from src/web/app/mobile/views/components/ui.nav.vue rename to src/server/web/app/mobile/views/components/ui.nav.vue diff --git a/src/web/app/mobile/views/components/ui.vue b/src/server/web/app/mobile/views/components/ui.vue similarity index 100% rename from src/web/app/mobile/views/components/ui.vue rename to src/server/web/app/mobile/views/components/ui.vue diff --git a/src/web/app/mobile/views/components/user-card.vue b/src/server/web/app/mobile/views/components/user-card.vue similarity index 100% rename from src/web/app/mobile/views/components/user-card.vue rename to src/server/web/app/mobile/views/components/user-card.vue diff --git a/src/web/app/mobile/views/components/user-preview.vue b/src/server/web/app/mobile/views/components/user-preview.vue similarity index 100% rename from src/web/app/mobile/views/components/user-preview.vue rename to src/server/web/app/mobile/views/components/user-preview.vue diff --git a/src/web/app/mobile/views/components/user-timeline.vue b/src/server/web/app/mobile/views/components/user-timeline.vue similarity index 100% rename from src/web/app/mobile/views/components/user-timeline.vue rename to src/server/web/app/mobile/views/components/user-timeline.vue diff --git a/src/web/app/mobile/views/components/users-list.vue b/src/server/web/app/mobile/views/components/users-list.vue similarity index 100% rename from src/web/app/mobile/views/components/users-list.vue rename to src/server/web/app/mobile/views/components/users-list.vue diff --git a/src/web/app/mobile/views/components/widget-container.vue b/src/server/web/app/mobile/views/components/widget-container.vue similarity index 100% rename from src/web/app/mobile/views/components/widget-container.vue rename to src/server/web/app/mobile/views/components/widget-container.vue diff --git a/src/web/app/mobile/views/directives/index.ts b/src/server/web/app/mobile/views/directives/index.ts similarity index 100% rename from src/web/app/mobile/views/directives/index.ts rename to src/server/web/app/mobile/views/directives/index.ts diff --git a/src/web/app/mobile/views/directives/user-preview.ts b/src/server/web/app/mobile/views/directives/user-preview.ts similarity index 100% rename from src/web/app/mobile/views/directives/user-preview.ts rename to src/server/web/app/mobile/views/directives/user-preview.ts diff --git a/src/web/app/mobile/views/pages/drive.vue b/src/server/web/app/mobile/views/pages/drive.vue similarity index 100% rename from src/web/app/mobile/views/pages/drive.vue rename to src/server/web/app/mobile/views/pages/drive.vue diff --git a/src/web/app/mobile/views/pages/followers.vue b/src/server/web/app/mobile/views/pages/followers.vue similarity index 100% rename from src/web/app/mobile/views/pages/followers.vue rename to src/server/web/app/mobile/views/pages/followers.vue diff --git a/src/web/app/mobile/views/pages/following.vue b/src/server/web/app/mobile/views/pages/following.vue similarity index 100% rename from src/web/app/mobile/views/pages/following.vue rename to src/server/web/app/mobile/views/pages/following.vue diff --git a/src/web/app/mobile/views/pages/home.vue b/src/server/web/app/mobile/views/pages/home.vue similarity index 100% rename from src/web/app/mobile/views/pages/home.vue rename to src/server/web/app/mobile/views/pages/home.vue diff --git a/src/web/app/mobile/views/pages/index.vue b/src/server/web/app/mobile/views/pages/index.vue similarity index 100% rename from src/web/app/mobile/views/pages/index.vue rename to src/server/web/app/mobile/views/pages/index.vue diff --git a/src/web/app/mobile/views/pages/messaging-room.vue b/src/server/web/app/mobile/views/pages/messaging-room.vue similarity index 100% rename from src/web/app/mobile/views/pages/messaging-room.vue rename to src/server/web/app/mobile/views/pages/messaging-room.vue diff --git a/src/web/app/mobile/views/pages/messaging.vue b/src/server/web/app/mobile/views/pages/messaging.vue similarity index 100% rename from src/web/app/mobile/views/pages/messaging.vue rename to src/server/web/app/mobile/views/pages/messaging.vue diff --git a/src/web/app/mobile/views/pages/notifications.vue b/src/server/web/app/mobile/views/pages/notifications.vue similarity index 100% rename from src/web/app/mobile/views/pages/notifications.vue rename to src/server/web/app/mobile/views/pages/notifications.vue diff --git a/src/web/app/mobile/views/pages/othello.vue b/src/server/web/app/mobile/views/pages/othello.vue similarity index 100% rename from src/web/app/mobile/views/pages/othello.vue rename to src/server/web/app/mobile/views/pages/othello.vue diff --git a/src/web/app/mobile/views/pages/post.vue b/src/server/web/app/mobile/views/pages/post.vue similarity index 100% rename from src/web/app/mobile/views/pages/post.vue rename to src/server/web/app/mobile/views/pages/post.vue diff --git a/src/web/app/mobile/views/pages/profile-setting.vue b/src/server/web/app/mobile/views/pages/profile-setting.vue similarity index 100% rename from src/web/app/mobile/views/pages/profile-setting.vue rename to src/server/web/app/mobile/views/pages/profile-setting.vue diff --git a/src/web/app/mobile/views/pages/search.vue b/src/server/web/app/mobile/views/pages/search.vue similarity index 100% rename from src/web/app/mobile/views/pages/search.vue rename to src/server/web/app/mobile/views/pages/search.vue diff --git a/src/web/app/mobile/views/pages/selectdrive.vue b/src/server/web/app/mobile/views/pages/selectdrive.vue similarity index 100% rename from src/web/app/mobile/views/pages/selectdrive.vue rename to src/server/web/app/mobile/views/pages/selectdrive.vue diff --git a/src/web/app/mobile/views/pages/settings.vue b/src/server/web/app/mobile/views/pages/settings.vue similarity index 100% rename from src/web/app/mobile/views/pages/settings.vue rename to src/server/web/app/mobile/views/pages/settings.vue diff --git a/src/web/app/mobile/views/pages/signup.vue b/src/server/web/app/mobile/views/pages/signup.vue similarity index 100% rename from src/web/app/mobile/views/pages/signup.vue rename to src/server/web/app/mobile/views/pages/signup.vue diff --git a/src/web/app/mobile/views/pages/user.vue b/src/server/web/app/mobile/views/pages/user.vue similarity index 100% rename from src/web/app/mobile/views/pages/user.vue rename to src/server/web/app/mobile/views/pages/user.vue diff --git a/src/web/app/mobile/views/pages/user/home.followers-you-know.vue b/src/server/web/app/mobile/views/pages/user/home.followers-you-know.vue similarity index 100% rename from src/web/app/mobile/views/pages/user/home.followers-you-know.vue rename to src/server/web/app/mobile/views/pages/user/home.followers-you-know.vue diff --git a/src/web/app/mobile/views/pages/user/home.friends.vue b/src/server/web/app/mobile/views/pages/user/home.friends.vue similarity index 100% rename from src/web/app/mobile/views/pages/user/home.friends.vue rename to src/server/web/app/mobile/views/pages/user/home.friends.vue diff --git a/src/web/app/mobile/views/pages/user/home.photos.vue b/src/server/web/app/mobile/views/pages/user/home.photos.vue similarity index 100% rename from src/web/app/mobile/views/pages/user/home.photos.vue rename to src/server/web/app/mobile/views/pages/user/home.photos.vue diff --git a/src/web/app/mobile/views/pages/user/home.posts.vue b/src/server/web/app/mobile/views/pages/user/home.posts.vue similarity index 100% rename from src/web/app/mobile/views/pages/user/home.posts.vue rename to src/server/web/app/mobile/views/pages/user/home.posts.vue diff --git a/src/web/app/mobile/views/pages/user/home.vue b/src/server/web/app/mobile/views/pages/user/home.vue similarity index 100% rename from src/web/app/mobile/views/pages/user/home.vue rename to src/server/web/app/mobile/views/pages/user/home.vue diff --git a/src/web/app/mobile/views/pages/welcome.vue b/src/server/web/app/mobile/views/pages/welcome.vue similarity index 100% rename from src/web/app/mobile/views/pages/welcome.vue rename to src/server/web/app/mobile/views/pages/welcome.vue diff --git a/src/web/app/mobile/views/widgets/activity.vue b/src/server/web/app/mobile/views/widgets/activity.vue similarity index 100% rename from src/web/app/mobile/views/widgets/activity.vue rename to src/server/web/app/mobile/views/widgets/activity.vue diff --git a/src/web/app/mobile/views/widgets/index.ts b/src/server/web/app/mobile/views/widgets/index.ts similarity index 100% rename from src/web/app/mobile/views/widgets/index.ts rename to src/server/web/app/mobile/views/widgets/index.ts diff --git a/src/web/app/mobile/views/widgets/profile.vue b/src/server/web/app/mobile/views/widgets/profile.vue similarity index 100% rename from src/web/app/mobile/views/widgets/profile.vue rename to src/server/web/app/mobile/views/widgets/profile.vue diff --git a/src/web/app/reset.styl b/src/server/web/app/reset.styl similarity index 100% rename from src/web/app/reset.styl rename to src/server/web/app/reset.styl diff --git a/src/web/app/safe.js b/src/server/web/app/safe.js similarity index 100% rename from src/web/app/safe.js rename to src/server/web/app/safe.js diff --git a/src/web/app/stats/style.styl b/src/server/web/app/stats/style.styl similarity index 100% rename from src/web/app/stats/style.styl rename to src/server/web/app/stats/style.styl diff --git a/src/web/app/stats/tags/index.tag b/src/server/web/app/stats/tags/index.tag similarity index 100% rename from src/web/app/stats/tags/index.tag rename to src/server/web/app/stats/tags/index.tag diff --git a/src/web/app/stats/tags/index.ts b/src/server/web/app/stats/tags/index.ts similarity index 100% rename from src/web/app/stats/tags/index.ts rename to src/server/web/app/stats/tags/index.ts diff --git a/src/web/app/status/style.styl b/src/server/web/app/status/style.styl similarity index 100% rename from src/web/app/status/style.styl rename to src/server/web/app/status/style.styl diff --git a/src/web/app/status/tags/index.tag b/src/server/web/app/status/tags/index.tag similarity index 100% rename from src/web/app/status/tags/index.tag rename to src/server/web/app/status/tags/index.tag diff --git a/src/web/app/status/tags/index.ts b/src/server/web/app/status/tags/index.ts similarity index 100% rename from src/web/app/status/tags/index.ts rename to src/server/web/app/status/tags/index.ts diff --git a/src/web/app/sw.js b/src/server/web/app/sw.js similarity index 100% rename from src/web/app/sw.js rename to src/server/web/app/sw.js diff --git a/src/web/app/tsconfig.json b/src/server/web/app/tsconfig.json similarity index 100% rename from src/web/app/tsconfig.json rename to src/server/web/app/tsconfig.json diff --git a/src/web/app/v.d.ts b/src/server/web/app/v.d.ts similarity index 100% rename from src/web/app/v.d.ts rename to src/server/web/app/v.d.ts diff --git a/src/web/assets/404.js b/src/server/web/assets/404.js similarity index 100% rename from src/web/assets/404.js rename to src/server/web/assets/404.js diff --git a/src/web/assets/code-highlight.css b/src/server/web/assets/code-highlight.css similarity index 100% rename from src/web/assets/code-highlight.css rename to src/server/web/assets/code-highlight.css diff --git a/src/web/assets/error.jpg b/src/server/web/assets/error.jpg similarity index 100% rename from src/web/assets/error.jpg rename to src/server/web/assets/error.jpg diff --git a/src/web/assets/favicon.ico b/src/server/web/assets/favicon.ico similarity index 100% rename from src/web/assets/favicon.ico rename to src/server/web/assets/favicon.ico diff --git a/src/web/assets/label.svg b/src/server/web/assets/label.svg similarity index 100% rename from src/web/assets/label.svg rename to src/server/web/assets/label.svg diff --git a/src/web/assets/manifest.json b/src/server/web/assets/manifest.json similarity index 100% rename from src/web/assets/manifest.json rename to src/server/web/assets/manifest.json diff --git a/src/web/assets/message.mp3 b/src/server/web/assets/message.mp3 similarity index 100% rename from src/web/assets/message.mp3 rename to src/server/web/assets/message.mp3 diff --git a/src/web/assets/othello-put-me.mp3 b/src/server/web/assets/othello-put-me.mp3 similarity index 100% rename from src/web/assets/othello-put-me.mp3 rename to src/server/web/assets/othello-put-me.mp3 diff --git a/src/web/assets/othello-put-you.mp3 b/src/server/web/assets/othello-put-you.mp3 similarity index 100% rename from src/web/assets/othello-put-you.mp3 rename to src/server/web/assets/othello-put-you.mp3 diff --git a/src/web/assets/post.mp3 b/src/server/web/assets/post.mp3 similarity index 100% rename from src/web/assets/post.mp3 rename to src/server/web/assets/post.mp3 diff --git a/src/web/assets/reactions/angry.png b/src/server/web/assets/reactions/angry.png similarity index 100% rename from src/web/assets/reactions/angry.png rename to src/server/web/assets/reactions/angry.png diff --git a/src/web/assets/reactions/confused.png b/src/server/web/assets/reactions/confused.png similarity index 100% rename from src/web/assets/reactions/confused.png rename to src/server/web/assets/reactions/confused.png diff --git a/src/web/assets/reactions/congrats.png b/src/server/web/assets/reactions/congrats.png similarity index 100% rename from src/web/assets/reactions/congrats.png rename to src/server/web/assets/reactions/congrats.png diff --git a/src/web/assets/reactions/hmm.png b/src/server/web/assets/reactions/hmm.png similarity index 100% rename from src/web/assets/reactions/hmm.png rename to src/server/web/assets/reactions/hmm.png diff --git a/src/web/assets/reactions/laugh.png b/src/server/web/assets/reactions/laugh.png similarity index 100% rename from src/web/assets/reactions/laugh.png rename to src/server/web/assets/reactions/laugh.png diff --git a/src/web/assets/reactions/like.png b/src/server/web/assets/reactions/like.png similarity index 100% rename from src/web/assets/reactions/like.png rename to src/server/web/assets/reactions/like.png diff --git a/src/web/assets/reactions/love.png b/src/server/web/assets/reactions/love.png similarity index 100% rename from src/web/assets/reactions/love.png rename to src/server/web/assets/reactions/love.png diff --git a/src/web/assets/reactions/pudding.png b/src/server/web/assets/reactions/pudding.png similarity index 100% rename from src/web/assets/reactions/pudding.png rename to src/server/web/assets/reactions/pudding.png diff --git a/src/web/assets/reactions/surprise.png b/src/server/web/assets/reactions/surprise.png similarity index 100% rename from src/web/assets/reactions/surprise.png rename to src/server/web/assets/reactions/surprise.png diff --git a/src/web/assets/recover.html b/src/server/web/assets/recover.html similarity index 100% rename from src/web/assets/recover.html rename to src/server/web/assets/recover.html diff --git a/src/web/assets/title.svg b/src/server/web/assets/title.svg similarity index 100% rename from src/web/assets/title.svg rename to src/server/web/assets/title.svg diff --git a/src/web/assets/unread.svg b/src/server/web/assets/unread.svg similarity index 100% rename from src/web/assets/unread.svg rename to src/server/web/assets/unread.svg diff --git a/src/web/assets/welcome-bg.svg b/src/server/web/assets/welcome-bg.svg similarity index 100% rename from src/web/assets/welcome-bg.svg rename to src/server/web/assets/welcome-bg.svg diff --git a/src/web/assets/welcome-fg.svg b/src/server/web/assets/welcome-fg.svg similarity index 100% rename from src/web/assets/welcome-fg.svg rename to src/server/web/assets/welcome-fg.svg diff --git a/src/web/const.styl b/src/server/web/const.styl similarity index 74% rename from src/web/const.styl rename to src/server/web/const.styl index b6560701d..f16e07782 100644 --- a/src/web/const.styl +++ b/src/server/web/const.styl @@ -1,4 +1,4 @@ -json('../const.json') +json('../../const.json') $theme-color = themeColor $theme-color-foreground = themeColorForeground diff --git a/src/web/docs/about.en.pug b/src/server/web/docs/about.en.pug similarity index 100% rename from src/web/docs/about.en.pug rename to src/server/web/docs/about.en.pug diff --git a/src/web/docs/about.ja.pug b/src/server/web/docs/about.ja.pug similarity index 100% rename from src/web/docs/about.ja.pug rename to src/server/web/docs/about.ja.pug diff --git a/src/web/docs/api.ja.pug b/src/server/web/docs/api.ja.pug similarity index 100% rename from src/web/docs/api.ja.pug rename to src/server/web/docs/api.ja.pug diff --git a/src/web/docs/api/endpoints/posts/create.yaml b/src/server/web/docs/api/endpoints/posts/create.yaml similarity index 100% rename from src/web/docs/api/endpoints/posts/create.yaml rename to src/server/web/docs/api/endpoints/posts/create.yaml diff --git a/src/web/docs/api/endpoints/posts/timeline.yaml b/src/server/web/docs/api/endpoints/posts/timeline.yaml similarity index 100% rename from src/web/docs/api/endpoints/posts/timeline.yaml rename to src/server/web/docs/api/endpoints/posts/timeline.yaml diff --git a/src/web/docs/api/endpoints/style.styl b/src/server/web/docs/api/endpoints/style.styl similarity index 100% rename from src/web/docs/api/endpoints/style.styl rename to src/server/web/docs/api/endpoints/style.styl diff --git a/src/web/docs/api/endpoints/view.pug b/src/server/web/docs/api/endpoints/view.pug similarity index 100% rename from src/web/docs/api/endpoints/view.pug rename to src/server/web/docs/api/endpoints/view.pug diff --git a/src/web/docs/api/entities/drive-file.yaml b/src/server/web/docs/api/entities/drive-file.yaml similarity index 100% rename from src/web/docs/api/entities/drive-file.yaml rename to src/server/web/docs/api/entities/drive-file.yaml diff --git a/src/web/docs/api/entities/post.yaml b/src/server/web/docs/api/entities/post.yaml similarity index 100% rename from src/web/docs/api/entities/post.yaml rename to src/server/web/docs/api/entities/post.yaml diff --git a/src/web/docs/api/entities/style.styl b/src/server/web/docs/api/entities/style.styl similarity index 100% rename from src/web/docs/api/entities/style.styl rename to src/server/web/docs/api/entities/style.styl diff --git a/src/web/docs/api/entities/user.yaml b/src/server/web/docs/api/entities/user.yaml similarity index 100% rename from src/web/docs/api/entities/user.yaml rename to src/server/web/docs/api/entities/user.yaml diff --git a/src/web/docs/api/entities/view.pug b/src/server/web/docs/api/entities/view.pug similarity index 100% rename from src/web/docs/api/entities/view.pug rename to src/server/web/docs/api/entities/view.pug diff --git a/src/web/docs/api/gulpfile.ts b/src/server/web/docs/api/gulpfile.ts similarity index 80% rename from src/web/docs/api/gulpfile.ts rename to src/server/web/docs/api/gulpfile.ts index cd1bf1530..37935413d 100644 --- a/src/web/docs/api/gulpfile.ts +++ b/src/server/web/docs/api/gulpfile.ts @@ -10,10 +10,10 @@ import * as pug from 'pug'; import * as yaml from 'js-yaml'; import * as mkdirp from 'mkdirp'; -import locales from '../../../../locales'; -import I18nReplacer from '../../../common/build/i18n'; -import fa from '../../../common/build/fa'; -import config from './../../../conf'; +import locales from '../../../../../locales'; +import I18nReplacer from '../../../../build/i18n'; +import fa from '../../../../build/fa'; +import config from './../../../../conf'; import generateVars from '../vars'; @@ -94,7 +94,7 @@ gulp.task('doc:api', [ gulp.task('doc:api:endpoints', async () => { const commonVars = await generateVars(); - glob('./src/web/docs/api/endpoints/**/*.yaml', (globErr, files) => { + glob('./src/server/web/docs/api/endpoints/**/*.yaml', (globErr, files) => { if (globErr) { console.error(globErr); return; @@ -115,10 +115,10 @@ gulp.task('doc:api:endpoints', async () => { resDefs: ep.res ? extractDefs(ep.res) : null, }; langs.forEach(lang => { - pug.renderFile('./src/web/docs/api/endpoints/view.pug', Object.assign({}, vars, { + pug.renderFile('./src/server/web/docs/api/endpoints/view.pug', Object.assign({}, vars, { lang, title: ep.endpoint, - src: `https://github.com/syuilo/misskey/tree/master/src/web/docs/api/endpoints/${ep.endpoint}.yaml`, + src: `https://github.com/syuilo/misskey/tree/master/src/server/web/docs/api/endpoints/${ep.endpoint}.yaml`, kebab, common: commonVars }), (renderErr, html) => { @@ -129,7 +129,7 @@ gulp.task('doc:api:endpoints', async () => { const i18n = new I18nReplacer(lang); html = html.replace(i18n.pattern, i18n.replacement); html = fa(html); - const htmlPath = `./built/web/docs/${lang}/api/endpoints/${ep.endpoint}.html`; + const htmlPath = `./built/server/web/docs/${lang}/api/endpoints/${ep.endpoint}.html`; mkdirp(path.dirname(htmlPath), (mkdirErr) => { if (mkdirErr) { console.error(mkdirErr); @@ -145,7 +145,7 @@ gulp.task('doc:api:endpoints', async () => { gulp.task('doc:api:entities', async () => { const commonVars = await generateVars(); - glob('./src/web/docs/api/entities/**/*.yaml', (globErr, files) => { + glob('./src/server/web/docs/api/entities/**/*.yaml', (globErr, files) => { if (globErr) { console.error(globErr); return; @@ -159,10 +159,10 @@ gulp.task('doc:api:entities', async () => { propDefs: extractDefs(entity.props), }; langs.forEach(lang => { - pug.renderFile('./src/web/docs/api/entities/view.pug', Object.assign({}, vars, { + pug.renderFile('./src/server/web/docs/api/entities/view.pug', Object.assign({}, vars, { lang, title: entity.name, - src: `https://github.com/syuilo/misskey/tree/master/src/web/docs/api/entities/${kebab(entity.name)}.yaml`, + src: `https://github.com/syuilo/misskey/tree/master/src/server/web/docs/api/entities/${kebab(entity.name)}.yaml`, kebab, common: commonVars }), (renderErr, html) => { @@ -173,7 +173,7 @@ gulp.task('doc:api:entities', async () => { const i18n = new I18nReplacer(lang); html = html.replace(i18n.pattern, i18n.replacement); html = fa(html); - const htmlPath = `./built/web/docs/${lang}/api/entities/${kebab(entity.name)}.html`; + const htmlPath = `./built/server/web/docs/${lang}/api/entities/${kebab(entity.name)}.html`; mkdirp(path.dirname(htmlPath), (mkdirErr) => { if (mkdirErr) { console.error(mkdirErr); diff --git a/src/web/docs/api/mixins.pug b/src/server/web/docs/api/mixins.pug similarity index 100% rename from src/web/docs/api/mixins.pug rename to src/server/web/docs/api/mixins.pug diff --git a/src/web/docs/api/style.styl b/src/server/web/docs/api/style.styl similarity index 100% rename from src/web/docs/api/style.styl rename to src/server/web/docs/api/style.styl diff --git a/src/web/docs/gulpfile.ts b/src/server/web/docs/gulpfile.ts similarity index 74% rename from src/web/docs/gulpfile.ts rename to src/server/web/docs/gulpfile.ts index d5ddda108..7b36cf667 100644 --- a/src/web/docs/gulpfile.ts +++ b/src/server/web/docs/gulpfile.ts @@ -11,8 +11,8 @@ import * as mkdirp from 'mkdirp'; import stylus = require('gulp-stylus'); import cssnano = require('gulp-cssnano'); -import I18nReplacer from '../../common/build/i18n'; -import fa from '../../common/build/fa'; +import I18nReplacer from '../../../build/i18n'; +import fa from '../../../build/fa'; import generateVars from './vars'; require('./api/gulpfile.ts'); @@ -26,7 +26,7 @@ gulp.task('doc', [ gulp.task('doc:docs', async () => { const commonVars = await generateVars(); - glob('./src/web/docs/**/*.*.pug', (globErr, files) => { + glob('./src/server/web/docs/**/*.*.pug', (globErr, files) => { if (globErr) { console.error(globErr); return; @@ -37,7 +37,7 @@ gulp.task('doc:docs', async () => { common: commonVars, lang: lang, title: fs.readFileSync(file, 'utf-8').match(/^h1 (.+?)\r?\n/)[1], - src: `https://github.com/syuilo/misskey/tree/master/src/web/docs/${name}.${lang}.pug`, + src: `https://github.com/syuilo/misskey/tree/master/src/server/web/docs/${name}.${lang}.pug`, }; pug.renderFile(file, vars, (renderErr, content) => { if (renderErr) { @@ -45,7 +45,7 @@ gulp.task('doc:docs', async () => { return; } - pug.renderFile('./src/web/docs/layout.pug', Object.assign({}, vars, { + pug.renderFile('./src/server/web/docs/layout.pug', Object.assign({}, vars, { content }), (renderErr2, html) => { if (renderErr2) { @@ -55,7 +55,7 @@ gulp.task('doc:docs', async () => { const i18n = new I18nReplacer(lang); html = html.replace(i18n.pattern, i18n.replacement); html = fa(html); - const htmlPath = `./built/web/docs/${lang}/${name}.html`; + const htmlPath = `./built/server/web/docs/${lang}/${name}.html`; mkdirp(path.dirname(htmlPath), (mkdirErr) => { if (mkdirErr) { console.error(mkdirErr); @@ -70,8 +70,8 @@ gulp.task('doc:docs', async () => { }); gulp.task('doc:styles', () => - gulp.src('./src/web/docs/**/*.styl') + gulp.src('./src/server/web/docs/**/*.styl') .pipe(stylus()) .pipe((cssnano as any)()) - .pipe(gulp.dest('./built/web/docs/assets/')) + .pipe(gulp.dest('./built/server/web/docs/assets/')) ); diff --git a/src/web/docs/index.en.pug b/src/server/web/docs/index.en.pug similarity index 100% rename from src/web/docs/index.en.pug rename to src/server/web/docs/index.en.pug diff --git a/src/web/docs/index.ja.pug b/src/server/web/docs/index.ja.pug similarity index 100% rename from src/web/docs/index.ja.pug rename to src/server/web/docs/index.ja.pug diff --git a/src/web/docs/layout.pug b/src/server/web/docs/layout.pug similarity index 100% rename from src/web/docs/layout.pug rename to src/server/web/docs/layout.pug diff --git a/src/web/docs/license.en.pug b/src/server/web/docs/license.en.pug similarity index 100% rename from src/web/docs/license.en.pug rename to src/server/web/docs/license.en.pug diff --git a/src/web/docs/license.ja.pug b/src/server/web/docs/license.ja.pug similarity index 100% rename from src/web/docs/license.ja.pug rename to src/server/web/docs/license.ja.pug diff --git a/src/web/docs/mute.ja.pug b/src/server/web/docs/mute.ja.pug similarity index 100% rename from src/web/docs/mute.ja.pug rename to src/server/web/docs/mute.ja.pug diff --git a/src/web/docs/search.ja.pug b/src/server/web/docs/search.ja.pug similarity index 100% rename from src/web/docs/search.ja.pug rename to src/server/web/docs/search.ja.pug diff --git a/src/web/docs/server.ts b/src/server/web/docs/server.ts similarity index 100% rename from src/web/docs/server.ts rename to src/server/web/docs/server.ts diff --git a/src/web/docs/style.styl b/src/server/web/docs/style.styl similarity index 100% rename from src/web/docs/style.styl rename to src/server/web/docs/style.styl diff --git a/src/web/docs/tou.ja.pug b/src/server/web/docs/tou.ja.pug similarity index 100% rename from src/web/docs/tou.ja.pug rename to src/server/web/docs/tou.ja.pug diff --git a/src/web/docs/ui.styl b/src/server/web/docs/ui.styl similarity index 100% rename from src/web/docs/ui.styl rename to src/server/web/docs/ui.styl diff --git a/src/web/docs/vars.ts b/src/server/web/docs/vars.ts similarity index 76% rename from src/web/docs/vars.ts rename to src/server/web/docs/vars.ts index 6f713f21d..5096a39c9 100644 --- a/src/web/docs/vars.ts +++ b/src/server/web/docs/vars.ts @@ -5,27 +5,27 @@ import * as yaml from 'js-yaml'; import * as licenseChecker from 'license-checker'; import * as tmp from 'tmp'; -import { fa } from '../../common/build/fa'; -import config from '../../conf'; -import { licenseHtml } from '../../common/build/license'; -const constants = require('../../const.json'); +import { fa } from '../../../build/fa'; +import config from '../../../conf'; +import { licenseHtml } from '../../../build/license'; +const constants = require('../../../const.json'); export default async function(): Promise<{ [key: string]: any }> { const vars = {} as { [key: string]: any }; - const endpoints = glob.sync('./src/web/docs/api/endpoints/**/*.yaml'); + const endpoints = glob.sync('./src/server/web/docs/api/endpoints/**/*.yaml'); vars['endpoints'] = endpoints.map(ep => { const _ep = yaml.safeLoad(fs.readFileSync(ep, 'utf-8')); return _ep.endpoint; }); - const entities = glob.sync('./src/web/docs/api/entities/**/*.yaml'); + const entities = glob.sync('./src/server/web/docs/api/entities/**/*.yaml'); vars['entities'] = entities.map(x => { const _x = yaml.safeLoad(fs.readFileSync(x, 'utf-8')); return _x.name; }); - const docs = glob.sync('./src/web/docs/**/*.*.pug'); + const docs = glob.sync('./src/server/web/docs/**/*.*.pug'); vars['docs'] = {}; docs.forEach(x => { const [, name, lang] = x.match(/docs\/(.+?)\.(.+?)\.pug$/); @@ -53,7 +53,7 @@ export default async function(): Promise<{ [key: string]: any }> { licenseText: '' }), 'utf-8'); const dependencies = await util.promisify(licenseChecker.init).bind(licenseChecker)({ - start: __dirname + '/../../../', + start: __dirname + '/../../../../', customPath: tmpObj.name }); tmpObj.removeCallback(); diff --git a/src/web/element.scss b/src/server/web/element.scss similarity index 91% rename from src/web/element.scss rename to src/server/web/element.scss index 917198e02..7e6d0e709 100644 --- a/src/web/element.scss +++ b/src/server/web/element.scss @@ -1,7 +1,7 @@ /* Element variable definitons */ /* SEE: http://element.eleme.io/#/en-US/component/custom-theme */ -@import '../const.json'; +@import '../../const.json'; /* theme color */ $--color-primary: $themeColor; diff --git a/src/web/server.ts b/src/server/web/server.ts similarity index 100% rename from src/web/server.ts rename to src/server/web/server.ts diff --git a/src/web/service/url-preview.ts b/src/server/web/service/url-preview.ts similarity index 100% rename from src/web/service/url-preview.ts rename to src/server/web/service/url-preview.ts diff --git a/src/web/style.styl b/src/server/web/style.styl similarity index 100% rename from src/web/style.styl rename to src/server/web/style.styl diff --git a/src/tools/analysis/core.ts b/src/tools/analysis/core.ts index 20e5fa6c5..839fffd3c 100644 --- a/src/tools/analysis/core.ts +++ b/src/tools/analysis/core.ts @@ -1,7 +1,7 @@ const bayes = require('./naive-bayes.js'); const MeCab = require('./mecab'); -import Post from '../../api/models/post'; +import Post from '../../server/api/models/post'; /** * 投稿を学習したり与えられた投稿のカテゴリを予測します diff --git a/src/tools/analysis/extract-user-domains.ts b/src/tools/analysis/extract-user-domains.ts index bc120f5c1..ba472b89a 100644 --- a/src/tools/analysis/extract-user-domains.ts +++ b/src/tools/analysis/extract-user-domains.ts @@ -1,8 +1,8 @@ import * as URL from 'url'; -import Post from '../../api/models/post'; -import User from '../../api/models/user'; -import parse from '../../api/common/text'; +import Post from '../../server/api/models/post'; +import User from '../../server/api/models/user'; +import parse from '../../server/api/common/text'; process.on('unhandledRejection', console.dir); diff --git a/src/tools/analysis/extract-user-keywords.ts b/src/tools/analysis/extract-user-keywords.ts index b99ca9321..4fa9b384e 100644 --- a/src/tools/analysis/extract-user-keywords.ts +++ b/src/tools/analysis/extract-user-keywords.ts @@ -1,9 +1,9 @@ const moji = require('moji'); const MeCab = require('./mecab'); -import Post from '../../api/models/post'; -import User from '../../api/models/user'; -import parse from '../../api/common/text'; +import Post from '../../server/api/models/post'; +import User from '../../server/api/models/user'; +import parse from '../../server/api/common/text'; process.on('unhandledRejection', console.dir); diff --git a/src/tools/analysis/predict-all-post-category.ts b/src/tools/analysis/predict-all-post-category.ts index 058c4f99e..8564fd1b1 100644 --- a/src/tools/analysis/predict-all-post-category.ts +++ b/src/tools/analysis/predict-all-post-category.ts @@ -1,4 +1,4 @@ -import Post from '../../api/models/post'; +import Post from '../../server/api/models/post'; import Core from './core'; const c = new Core(); diff --git a/src/tools/analysis/predict-user-interst.ts b/src/tools/analysis/predict-user-interst.ts index 99bdfa420..6599fb220 100644 --- a/src/tools/analysis/predict-user-interst.ts +++ b/src/tools/analysis/predict-user-interst.ts @@ -1,5 +1,5 @@ -import Post from '../../api/models/post'; -import User from '../../api/models/user'; +import Post from '../../server/api/models/post'; +import User from '../../server/api/models/user'; export async function predictOne(id) { console.log(`predict interest of ${id} ...`); diff --git a/test/api.js b/test/api.js index b8b2aecc9..c2c08dd95 100644 --- a/test/api.js +++ b/test/api.js @@ -17,7 +17,7 @@ const should = _chai.should(); _chai.use(chaiHttp); -const server = require('../built/api/server'); +const server = require('../built/server/api/server'); const db = require('../built/db/mongodb').default; const async = fn => (done) => { diff --git a/test/text.js b/test/text.js index 3b27aa23d..4f739cc1b 100644 --- a/test/text.js +++ b/test/text.js @@ -4,8 +4,8 @@ const assert = require('assert'); -const analyze = require('../built/api/common/text').default; -const syntaxhighlighter = require('../built/api/common/text/core/syntax-highlighter').default; +const analyze = require('../built/server/api/common/text').default; +const syntaxhighlighter = require('../built/server/api/common/text/core/syntax-highlighter').default; describe('Text', () => { it('can be analyzed', () => { diff --git a/tsconfig.json b/tsconfig.json index 47aa521bf..574c11bac 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -21,6 +21,6 @@ "./src/**/*.ts" ], "exclude": [ - "./src/web/app/**/*.ts" + "./src/server/web/app/**/*.ts" ] } diff --git a/webpack.config.ts b/webpack.config.ts index 9a952c8ef..6f16fcbfa 100644 --- a/webpack.config.ts +++ b/webpack.config.ts @@ -11,11 +11,11 @@ const WebpackOnBuildPlugin = require('on-build-webpack'); //const HardSourceWebpackPlugin = require('hard-source-webpack-plugin'); const ProgressBarPlugin = require('progress-bar-webpack-plugin'); -import I18nReplacer from './src/common/build/i18n'; -import { pattern as faPattern, replacement as faReplacement } from './src/common/build/fa'; +import I18nReplacer from './src/build/i18n'; +import { pattern as faPattern, replacement as faReplacement } from './src/build/fa'; const constants = require('./src/const.json'); import config from './src/conf'; -import { licenseHtml } from './src/common/build/license'; +import { licenseHtml } from './src/build/license'; import locales from './locales'; const meta = require('./package.json'); @@ -33,7 +33,7 @@ global['collapseSpacesReplacement'] = html => { }; global['base64replacement'] = (_, key) => { - return fs.readFileSync(__dirname + '/src/web/' + key, 'base64'); + return fs.readFileSync(__dirname + '/src/server/web/' + key, 'base64'); }; //#endregion @@ -51,18 +51,18 @@ module.exports = entries.map(x => { // Entries const entry = { - desktop: './src/web/app/desktop/script.ts', - mobile: './src/web/app/mobile/script.ts', - //ch: './src/web/app/ch/script.ts', - //stats: './src/web/app/stats/script.ts', - //status: './src/web/app/status/script.ts', - dev: './src/web/app/dev/script.ts', - auth: './src/web/app/auth/script.ts', - sw: './src/web/app/sw.js' + desktop: './src/server/web/app/desktop/script.ts', + mobile: './src/server/web/app/mobile/script.ts', + //ch: './src/server/web/app/ch/script.ts', + //stats: './src/server/web/app/stats/script.ts', + //status: './src/server/web/app/status/script.ts', + dev: './src/server/web/app/dev/script.ts', + auth: './src/server/web/app/auth/script.ts', + sw: './src/server/web/app/sw.js' }; const output = { - path: __dirname + '/built/web/assets', + path: __dirname + '/built/server/web/assets', filename: `[name].${version}.${lang}.${isProduction ? 'min' : 'raw'}.js` }; @@ -206,7 +206,7 @@ module.exports = entries.map(x => { loader: 'ts-loader', options: { happyPackMode: true, - configFile: __dirname + '/../src/web/app/tsconfig.json', + configFile: __dirname + '/../src/server/web/app/tsconfig.json', appendTsSuffixTo: [/\.vue$/] } }, { @@ -231,7 +231,7 @@ module.exports = entries.map(x => { '.js', '.ts', '.json' ], alias: { - 'const.styl': __dirname + '/src/web/const.styl' + 'const.styl': __dirname + '/src/server/web/const.styl' } }, resolveLoader: {