Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
c2b8d77
WIP: migrate from Webpack to Esbuild.
conradwt Mar 29, 2022
a88cc76
Update the assets folder.
conradwt Mar 29, 2022
e001e68
Relocate items in assets/static to priv/static.
conradwt Mar 29, 2022
fd4a2d0
Update images location.
conradwt Mar 29, 2022
5410c54
Update app.js and app.css references.
conradwt Mar 29, 2022
78807f0
Update files for migration to Tailwind.
conradwt Apr 26, 2022
1f489ec
Rename path.
conradwt Apr 26, 2022
58a9813
Upgrade Elixir Hex packages. (#125)
conradwt May 12, 2022
7712f83
Upgrade to Erlang 25.0. (#126)
conradwt May 19, 2022
d4d6613
Upgrade to Erlang 25.0.1. (#127)
conradwt Jun 11, 2022
790f76c
Fix configuration files.
conradwt Jul 11, 2022
5c49a4b
Upgrade software requirements. (#129)
conradwt Jul 18, 2022
99c43e8
Bump to Elixir 1.14.0
conradwt Sep 1, 2022
0d0aa43
Upgrade-software-requirements (#130)
conradwt Sep 15, 2022
f2a9d50
Update to Erlang 25.1 and refresh Hex packages. (#131)
conradwt Sep 23, 2022
bac98e5
Upgrade to Erlang 25.1.1. (#133)
conradwt Oct 3, 2022
11d3d07
Upgrade system requirements. (#134)
conradwt Oct 24, 2022
7306f7c
Upgrade to Phoenix 1.6.15, Elixir 1.14.2, and Erlang 25.2. (#135)
conradwt Dec 16, 2022
9f1654d
Remove support for Heroku. (#136)
conradwt Jan 6, 2023
73f49df
Update documentation.
conradwt Jan 10, 2023
0037af0
Upgrade software requirements and refresh Hex packages. (#141)
conradwt Jan 17, 2023
387c907
Upgrade to Erlang 25.3. (#143)
conradwt Mar 9, 2023
1131c62
Update to use the global iex config file. (#144)
conradwt Mar 17, 2023
b54d20a
Upgrade system requirements. (#145)
conradwt Apr 4, 2023
8e4b9f0
Update to Erlang 25.3.1. (#146)
conradwt Apr 29, 2023
425c275
Upgrade to Erlang 25.3.2. (#147)
conradwt May 7, 2023
da55dea
Update Ecto dependencies and system requirements. (#148)
conradwt Jun 5, 2023
cd9f9e4
Fix image uploader and correct Tailwind setup. (#149)
conradwt Jun 6, 2023
60a9aaa
Downgrade to Erlang 25.3.2.2. (#150)
conradwt Jun 12, 2023
ff70ac5
Fix browser list warning message.
conradwt Jun 12, 2023
0fd42c2
Migrate header and footer to Tailwind.
conradwt Jun 13, 2023
58730b6
Upgrade to Elixir 1.15.0. (#151)
conradwt Jun 23, 2023
b6f441b
Update to Elixir 1.15.2 and refresh Hex packages. (#152)
conradwt Jul 5, 2023
55f959c
Refresh Hex packages. (#153)
conradwt Jul 11, 2023
f47de11
Update to Elixir 1.15.3 and refresh Hex packages. (#154)
conradwt Jul 18, 2023
9517f32
Update to Elixir 1.15.4. (#155)
conradwt Jul 19, 2023
6e1947c
Update-to-bandit-1.0.0-pre.13 (#156)
conradwt Aug 22, 2023
98ab7c1
Update to Elixir 1.15.5. (#157)
conradwt Aug 29, 2023
e4fae77
Update to PostgreSQL 15.4.
conradwt Aug 31, 2023
cdb2b64
Update to system requirements and refresh Hex packages. (#159)
conradwt Oct 25, 2023
017b0e8
Update to Elixir 1.16.0.
conradwt Jan 2, 2024
dae2a78
Update Hex packages.
conradwt Jan 8, 2024
7049b96
Update Hex packages.
conradwt Jan 23, 2024
44e86dc
Update system requirements and Hex packages. (#163)
conradwt Mar 30, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
210 changes: 210 additions & 0 deletions .credo.exs
Original file line number Diff line number Diff line change
@@ -0,0 +1,210 @@
# This file contains the configuration for Credo and you are probably reading
# this after creating it with `mix credo.gen.config`.
#
# If you find anything wrong or unclear in this file, please report an
# issue on GitHub: https://github.com/rrrene/credo/issues
#
%{
#
# You can have as many configs as you like in the `configs:` field.
configs: [
%{
#
# Run any config using `mix credo -C <name>`. If no config name is given
# "default" is used.
#
name: "default",
#
# These are the files included in the analysis:
files: %{
#
# You can give explicit globs or simply directories.
# In the latter case `**/*.{ex,exs}` will be used.
#
included: [
"lib/",
"src/",
"test/",
"web/",
"apps/*/lib/",
"apps/*/src/",
"apps/*/test/",
"apps/*/web/"
],
excluded: [~r"/_build/", ~r"/deps/", ~r"/node_modules/"]
},
#
# Load and configure plugins here:
#
plugins: [],
#
# If you create your own checks, you must specify the source files for
# them here, so they can be loaded by Credo before running the analysis.
#
requires: [],
#
# If you want to enforce a style guide and need a more traditional linting
# experience, you can change `strict` to `true` below:
#
strict: false,
#
# To modify the timeout for parsing files, change this value:
#
parse_timeout: 5000,
#
# If you want to use uncolored output by default, you can change `color`
# to `false` below:
#
color: true,
#
# You can customize the parameters of any check by adding a second element
# to the tuple.
#
# To disable a check put `false` as second element:
#
# {Credo.Check.Design.DuplicatedCode, false}
#
checks: %{
enabled: [
#
## Consistency Checks
#
{Credo.Check.Consistency.ExceptionNames, []},
{Credo.Check.Consistency.LineEndings, []},
{Credo.Check.Consistency.ParameterPatternMatching, []},
{Credo.Check.Consistency.SpaceAroundOperators, []},
{Credo.Check.Consistency.SpaceInParentheses, []},
{Credo.Check.Consistency.TabsOrSpaces, []},

#
## Design Checks
#
# You can customize the priority of any check
# Priority values are: `low, normal, high, higher`
#
{Credo.Check.Design.AliasUsage,
[priority: :low, if_nested_deeper_than: 2, if_called_more_often_than: 0]},
# You can also customize the exit_status of each check.
# If you don't want TODO comments to cause `mix credo` to fail, just
# set this value to 0 (zero).
#
{Credo.Check.Design.TagTODO, [exit_status: 2]},
{Credo.Check.Design.TagFIXME, []},

#
## Readability Checks
#
{Credo.Check.Readability.AliasOrder, []},
{Credo.Check.Readability.FunctionNames, []},
{Credo.Check.Readability.LargeNumbers, []},
{Credo.Check.Readability.MaxLineLength, [priority: :low, max_length: 120]},
{Credo.Check.Readability.ModuleAttributeNames, []},
{Credo.Check.Readability.ModuleDoc, []},
{Credo.Check.Readability.ModuleNames, []},
{Credo.Check.Readability.ParenthesesInCondition, []},
{Credo.Check.Readability.ParenthesesOnZeroArityDefs, []},
{Credo.Check.Readability.PipeIntoAnonymousFunctions, []},
{Credo.Check.Readability.PredicateFunctionNames, []},
{Credo.Check.Readability.PreferImplicitTry, []},
{Credo.Check.Readability.RedundantBlankLines, []},
{Credo.Check.Readability.Semicolons, []},
{Credo.Check.Readability.SpaceAfterCommas, []},
{Credo.Check.Readability.StringSigils, []},
{Credo.Check.Readability.TrailingBlankLine, []},
{Credo.Check.Readability.TrailingWhiteSpace, []},
{Credo.Check.Readability.UnnecessaryAliasExpansion, []},
{Credo.Check.Readability.VariableNames, []},
{Credo.Check.Readability.WithSingleClause, []},

#
## Refactoring Opportunities
#
{Credo.Check.Refactor.Apply, []},
{Credo.Check.Refactor.CondStatements, []},
{Credo.Check.Refactor.CyclomaticComplexity, []},
{Credo.Check.Refactor.FunctionArity, []},
{Credo.Check.Refactor.LongQuoteBlocks, []},
{Credo.Check.Refactor.MatchInCondition, []},
{Credo.Check.Refactor.MapJoin, []},
{Credo.Check.Refactor.NegatedConditionsInUnless, []},
{Credo.Check.Refactor.NegatedConditionsWithElse, []},
{Credo.Check.Refactor.Nesting, []},
{Credo.Check.Refactor.UnlessWithElse, []},
{Credo.Check.Refactor.WithClauses, []},
{Credo.Check.Refactor.FilterFilter, []},
{Credo.Check.Refactor.RejectReject, []},
{Credo.Check.Refactor.RedundantWithClauseResult, []},

#
## Warnings
#
{Credo.Check.Warning.ApplicationConfigInModuleAttribute, []},
{Credo.Check.Warning.BoolOperationOnSameValues, []},
{Credo.Check.Warning.ExpensiveEmptyEnumCheck, []},
{Credo.Check.Warning.IExPry, []},
{Credo.Check.Warning.IoInspect, []},
{Credo.Check.Warning.OperationOnSameValues, []},
{Credo.Check.Warning.OperationWithConstantResult, []},
{Credo.Check.Warning.RaiseInsideRescue, []},
{Credo.Check.Warning.SpecWithStruct, []},
{Credo.Check.Warning.WrongTestFileExtension, []},
{Credo.Check.Warning.UnusedEnumOperation, []},
{Credo.Check.Warning.UnusedFileOperation, []},
{Credo.Check.Warning.UnusedKeywordOperation, []},
{Credo.Check.Warning.UnusedListOperation, []},
{Credo.Check.Warning.UnusedPathOperation, []},
{Credo.Check.Warning.UnusedRegexOperation, []},
{Credo.Check.Warning.UnusedStringOperation, []},
{Credo.Check.Warning.UnusedTupleOperation, []},
{Credo.Check.Warning.UnsafeExec, []}
],
disabled: [
#
# Checks scheduled for next check update (opt-in for now, just replace `false` with `[]`)

#
# Controversial and experimental checks (opt-in, just move the check to `:enabled`
# and be sure to use `mix credo --strict` to see low priority checks)
#
{Credo.Check.Consistency.MultiAliasImportRequireUse, []},
{Credo.Check.Consistency.UnusedVariableNames, []},
{Credo.Check.Design.DuplicatedCode, []},
{Credo.Check.Design.SkipTestWithoutComment, []},
{Credo.Check.Readability.AliasAs, []},
{Credo.Check.Readability.BlockPipe, []},
{Credo.Check.Readability.ImplTrue, []},
{Credo.Check.Readability.MultiAlias, []},
{Credo.Check.Readability.NestedFunctionCalls, []},
{Credo.Check.Readability.SeparateAliasRequire, []},
{Credo.Check.Readability.SingleFunctionToBlockPipe, []},
{Credo.Check.Readability.SinglePipe, []},
{Credo.Check.Readability.Specs, []},
{Credo.Check.Readability.StrictModuleLayout, []},
{Credo.Check.Readability.WithCustomTaggedTuple, []},
{Credo.Check.Refactor.ABCSize, []},
{Credo.Check.Refactor.AppendSingleItem, []},
{Credo.Check.Refactor.DoubleBooleanNegation, []},
{Credo.Check.Refactor.FilterReject, []},
{Credo.Check.Refactor.IoPuts, []},
{Credo.Check.Refactor.MapMap, []},
{Credo.Check.Refactor.ModuleDependencies, []},
{Credo.Check.Refactor.NegatedIsNil, []},
{Credo.Check.Refactor.PipeChainStart, []},
{Credo.Check.Refactor.RejectFilter, []},
{Credo.Check.Refactor.VariableRebinding, []},
{Credo.Check.Warning.LazyLogging, []},
{Credo.Check.Warning.LeakyEnvironment, []},
{Credo.Check.Warning.MapGetUnsafePass, []},
{Credo.Check.Warning.MixEnv, []},
{Credo.Check.Warning.UnsafeToAtom, []}

# {Credo.Check.Refactor.MapInto, []},

#
# Custom checks can be created using `mix credo.gen.check`.
#
]
}
}
]
}
12 changes: 5 additions & 7 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -22,16 +22,14 @@ erl_crash.dump
# Ignore package tarball (built via "mix hex.build").
flix-*.tar

# If NPM crashes, it generates a log, let's ignore it too.
# In case you use Node.js/npm, you want to ignore these.
npm-debug.log

# The directory NPM downloads your dependencies sources to.
/assets/node_modules/

# Since we are building assets from assets/,
# we ignore priv/static. You may want to comment
# this depending on your deployment strategy.
/priv/static/
# Ignore assets that are produced by build tools.
/priv/static/assets/

# Ignore image assets generated during development.
/uploads

# Ignore VS Code application files.
Expand Down
6 changes: 3 additions & 3 deletions .iex.exs
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
IEx.configure(inspect: [charlists: false])
import_file_if_available("~/.iex.exs")

import Ecto.Query

alias Flix.Accounts
alias Flix.Accounts.User
Expand All @@ -11,5 +13,3 @@ alias Flix.Catalogs.Movie
alias Flix.Catalogs.Review

alias Flix.Repo

import Ecto.Query
4 changes: 2 additions & 2 deletions .tool-versions
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
erlang 24.3.3
elixir 1.13.3-otp-24
elixir 1.16.2-otp-26
erlang 26.2.3
16 changes: 7 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,20 @@
# Flix

The purpose of this project is to implement an application where fans can comment on and rate movies. Also, the running application can be found [here](https://flix-elixir-cwt.herokuapp.com).
The purpose of this project is to implement an application where fans can comment on and rate movies. Also, the running application can be found [here](https://www.example.com).

## Getting Started

## Software requirements

- Elixir 1.13.3 or newer
- Elixir 1.16.2 or newer

- Erlang 24.3.3 or newer
- Erlang 26.2.3 or newer

- Node >= 14.19.0 and <= 15.0
- Phoenix 1.6.16 or newer

- Phoenix 1.6.7 or newer
- PostgreSQL 15.6 or newer

- PostgreSQL 14.1 or newer

Note: This tutorial was updated on macOS 12.3.1.
Note: This tutorial was updated on macOS 14.4.1.

## Communication

Expand Down Expand Up @@ -88,4 +86,4 @@ Flix is released under the [MIT license](./LICENSE.md).

## Copyright

copyright:: (c) Copyright 2021 - 2022 Conrad Taylor. All Rights Reserved.
copyright:: (c) Copyright 2021 - 2024 Conrad Taylor. All Rights Reserved.
5 changes: 0 additions & 5 deletions assets/.babelrc

This file was deleted.

14 changes: 11 additions & 3 deletions assets/css/app.scss
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
/* This file is for your main application css. */
// @import './phoenix.css';
@import '~bootstrap/scss/bootstrap.scss';
@import './css/custom.scss';
@tailwind base;
@tailwind components;
@tailwind utilities;

// @import './custom.scss';

/* Alerts and form errors */
.alert {
Expand All @@ -10,27 +12,33 @@
border: 1px solid transparent;
border-radius: 4px;
}

.alert-info {
color: #31708f;
background-color: #d9edf7;
border-color: #bce8f1;
}

.alert-warning {
color: #8a6d3b;
background-color: #fcf8e3;
border-color: #faebcc;
}

.alert-danger {
color: #a94442;
background-color: #f2dede;
border-color: #ebccd1;
}

.alert p {
margin-bottom: 0;
}

.alert:empty {
display: none;
}

.invalid-feedback {
color: #a94442;
display: block;
Expand Down
Loading