Skip to content

Instantly share code, notes, and snippets.

@dizballanze
Last active August 29, 2015 13:57
Show Gist options
  • Save dizballanze/9831063 to your computer and use it in GitHub Desktop.
Save dizballanze/9831063 to your computer and use it in GitHub Desktop.
Debugmail file stracture

Корень файловой системы:

API.md - описание REST Api
app/ - backend приложение
bin/ - скрипты для запуска сервисов
bower_components/ - сюда ставятся фронтенд компоненты из bower
bower.json - зависимости по фронтенду
coffeelint.json - настройки линтера
fapp/ - фронтенд приложение
gruntfile.coffee - сборка статики
Makefile - команды для запуска/перезапуска/остановки сервисов в разных режимах, деплойя и тд
node_modules/ - модули ноды
package.json - зависимости ноды
README.md - документация
static/ - сюда собирается статика
test/ - все тесты
var/ - логи

Бекенд приложение:

app/:
    application.coffee controllers middlewares.coffee params.coffee routes.coffee
    sample_data.coffee settings_local.coffee templates configure.coffee
    filters.coffee models pubsub rundev.coffee settings.coffee smtp tools

app/controllers:
    mails.coffee  projects.coffee  users.coffee

app/models:
    mail.coffee  project.coffee  user.coffee

app/pubsub:
    auth.coffee  server.coffee

app/smtp:
    auth.coffee  media_type_resolver.coffee  save.coffee  server.coffee

app/templates:
    index.ect  mails

app/templates/mails:
    project_invite.ect  registration.ect  restore_password.ect  social_registration.ect

app/tools:
    coment.coffee  mailer.coffee  social_auth.coffee

Фронтенд приложение:

fapp/:
controllers debugmail.coffee fake-backend.coffee filters models templates

fapp/controllers:
    about.coffee auth.coffee home.coffee mails-public.coffee
    projects.coffee projects-edit.coffee projects-new.coffee

fapp/filters:
debugmail.coffee  dropdowns.coffee  infinite-scroll.coffee

fapp/models:
auth.coffee  faye.coffee  projects.coffee

fapp/templates:
    about.html changepassword.html loading.html projects-edit.html projects-header.html
    projects-mails.html projects-projects.html signin.html auth-header.html home.html
    projects-contents.html projects-footer.html projects.html projects-new.html
    restorepassword.html signup.html

Скрипты для запуска сервисов:

bin/:
    app pubsub smtp

Скрипт выглядит примерно так:

#!/usr/bin/env node
require("coffee-script");
create_app = require("../app/application");
app = create_app();
app.listen(5000);
console.log("Application running on http://localhost:5000/");
console.log("(" + process.env.NODE_ENV + " mode)");

Тесты:

test/:
    attachments  _auth.coffee  _db.coffee  functional  _mails.coffee  mocha.opts
    _projects.coffee  _request.coffee  tmp_upload unit

test/attachments:
    test_image.jpeg  test_other.bin  test_video.mov

test/functional:
    test_app.coffee  test_mails.coffee  test_projects.coffee  test_pubsub.coffee  test_smtp_server.coffee  test_users.coffee

test/unit:
    templates test_filters.coffee test_middlewares.coffee
    test_projects_contoller.coffee test_smtp_save.coffee
    test_users_controller.coffee test_coment.coffee test_mailer.coffee
    test_models.coffee test_pubsub_auth.coffee test_smtp_type_resolver.coffee
    test_configure.coffee test_mails_controller.coffee test_params.coffee test_smtp_auth.coffee test_social_auth_process.coffee

test/unit/templates:
    letter.ect  letter-plain.ect
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment