Commit graph

390 commits

Author SHA1 Message Date
Kieran
0f40dcf5dd Clarifies wording of source form for index frequency (#47) 2024-03-02 13:09:58 -08:00
Kieran
c37157d644 Support audio only downloads (#46)
* Adds option to only download audio

* Improves helper text for profile options
2024-03-02 13:01:47 -08:00
Kieran
09448e3fcc Source attributes in output template (#45)
* Updated download options to take a media item; allowed for specifying custom output path template options

* Fixed bug where indexing job wouldn't run for the first time

* Renamed friendly_name to custom_name

* Added new options to default template and UI

* Improved explainer UI
2024-03-02 12:15:10 -08:00
Kieran
9e75092876 Pre-prepare for alpha launch (#44)
* Add an initial version

* Add a license
2024-03-01 19:47:19 -08:00
Kieran
36f27c76e8 Useful data on homepage v1 (#43)
* Made the homepage _slightly_ more useful

* Very minor refactor in alpine body-level object
2024-03-01 18:25:55 -08:00
Kieran
be8bcf0eb2 Improve relationship UI handling (#42)
* Added tabbed view; improved relationships for media profile

* Adds new maybe_limit method for queries

* Improves UI for media items, associated tasks
2024-02-29 18:35:51 -08:00
Kieran
7809a25f2d Responsive UI improvements (#41)
* Improved responsive UX for media profiles

* Improved responsiveness for other pages

* Added docs; fixed up stragglers
2024-02-29 17:51:54 -08:00
Kieran
d2c2cda479 Added some logos up in this (#40) 2024-02-29 17:37:14 -08:00
Kieran
1f4823bda9 UX improvements v1 (#39)
* Removed collection_type user input instead inferring from yt-dlp response

* Updated docs

* Added delete buttons for source; Refactored the way deletion methods work

* Update source to always run an initial index

* Added deletion to the last models

* Improved clarity around deletion operation

* Improved task fetching and deletion methods

* More tests
2024-02-28 18:54:01 -08:00
Kieran
0020e5083b Resolved windows filesystem bug (#38) 2024-02-28 17:56:25 -08:00
Kieran
c77047951f Improve metadata storage (#37)
* Updated config path to specify metadata storage path

* Removed metadata column from DB, replacing it with filepath columns

* Updated app to store compressed metadata; automatically download thumbnails

* Ensured metadata is deleted when other files are deleted

* Updated docs

* Added inets to application start so http calls work in prod
2024-02-24 13:40:05 -08:00
Kieran
4094da9e03 Small form improvements (#36)
* Clarified intent of custom name field

* More copy improvements
2024-02-22 18:48:25 -08:00
Kieran
3b94b269d9 Updated video downloader to use full URL; improved docs (#35) 2024-02-22 17:46:08 -08:00
Kieran Eglin
927560beb6 Updated docker build to only run on dispatch 2024-02-22 17:30:09 -08:00
Kieran
ab9b657394 Docker build action (round 2) (#34)
* Added first attempt at dockerfile

* Added workflow dispatch [skip ci]

* Trying PR trigger just for now [skip ci]

* Trying some more [skip ci]

* Revert for merge
2024-02-21 18:19:06 -08:00
Kieran
610acb15f1 Added log rotation for prod config (#32) 2024-02-21 18:01:18 -08:00
Kieran
3efc533fb7 Added optional basic auth (#31) 2024-02-21 17:37:25 -08:00
Kieran
e3f1b409b9 Improve dev tooling (#30)
* added ex_check and got it passing

* Set up ex_check to run in test env

* Added static code analysis

* Updated actions file

* Updated dockerfile
2024-02-21 17:28:27 -08:00
Kieran
01042ebd1b Updated source's friendly_name to default to the collection_name (#29) 2024-02-20 19:24:47 -08:00
Kieran
1ec1a48235 Refactor and document output path (#28)
* Updated output path builder to better use yt-dlp variables

* Added UI explaining output template options

* Fixed outdated reference in dockerfile
2024-02-20 18:40:13 -08:00
Kieran
af7e76c1d1 Rename media sources (#25)
* Renamed MediaSource to Sources

* Renamed MediaItem controller namespace
2024-02-20 17:48:20 -08:00
Kieran
69c47c2c65 Basic onboading flow (#24)
* removed unused file

* [WIP] Created onboarding form

* Finished basic onboarding flow; added tests

* Improved onboarding language
2024-02-20 17:37:17 -08:00
Kieran
1f56db01a5 Prod packaging v1 (#23)
* Sets media directory for prod

* Improved logging; Added docker files for prod

* Improved fetching SECRET_KEY_BASE for selfhosted instances
2024-02-16 18:50:00 -08:00
Kieran
b81c8d64b3 Switch to sqlite (#22)
* Updated project to use sqlite

* Edited migrations directly because I fear no man

* Updated search functions and tests to work with sqlite

* Updated build tools to remove postgres
2024-02-16 17:11:41 -08:00
Kieran
53bd8681c3 Add resolution option (#21)
* added preferred resolution to profiles

* Add resolution to download option builder
2024-02-15 18:21:41 -08:00
Kieran
c5fcb8fe12 Delete media items (#20)
* Added method for deleting media files and their content

* Adds controllers and methods for deleting media and files

* Improved tmpfile setup and teardown for tests

* Actually got tmpfile cleanup running once per suite run

* Finally fixed flash messages
2024-02-15 17:51:19 -08:00
Kieran
58771ee37b Search v1 (#19)
* Adds description to media items; hooks it up to indexing/media downloading

* Added a search method using postgres fulltext search

* Hooked up search functionality to the search form

* Added persistence to the search form when on search page
2024-02-13 17:46:14 -08:00
Kieran
850cf2db73 Media item lifecycle improvements (#18)
* Added jobs for enqueuing/dequeuing media based on source's status

* adds lifecycle columns to source and media_item tables
2024-02-09 20:51:23 -08:00
Kieran
77f06bfbc8 Media UI v1 (#17)
* Updated comments

* Added basic media tables to sources#show

* Adds a very basic listing and show page for media
2024-02-09 19:21:51 -08:00
Kieran
e0637331bb Redo indexing mechanism (#16)
* Bumped up the line length because I fear no man

* Refactored indexing

Previously, indexing worked by collecting the video IDs of only videos
that matched indexing criteria. This new model instead stores ALL videos
for a given source, but will only _download_ videos that meet that criteria.
This lets us backfill without indexing, makes it easier to add in other
backends, lets us download one-off videos for a source that don't quite
meet criteria, you name it.

* Updated media finders to respect format filters; Added credo file
2024-02-09 18:23:37 -08:00
Kieran
e1565ad22f First UI Pass (#15)
* Added scratchpad dir

* Installed Alpine

* [WIP] began integrating Tailwind and accompanying theme

* [WIP] Set up basic views for sources

* Adds new UI to media profiles page

* Removes unneeded view
2024-02-08 19:03:11 -08:00
Kieran
9e4fbfa35d Media downloading indexing options (round 2) (#14)
* Adds options + option builder + metadata parsing for media thumbnails

* Added release-type options to media profile; built option parser for indexing operations

* Added new media_profile options to creation form; made show helper for rendering database items

* Added options for downloading/embedding metadata

* Adds option on sources to not download media (index only)

* reformatted docs
2024-02-06 18:36:41 -08:00
Kieran
b19c01e3ed Start integrating playlist support (#13)
* [WIP] updated the output of VideoCollection to include playlists

* Updated source's name to collection_name; supported playlist ID/name fetching

* Hooked up collection_type to form; refactored enqueue_pending_media_downloads

* Added friendly_name to form

* Added media profile link to source view

* Updates comment
2024-02-05 17:38:19 -08:00
Kieran
366fd80213 Change Channel to Source (#12)
* Ensure channel detail lookup doesn't download the video - oops

* Ran the needful migrations for replacing channels with sources

* got media source test back working

* channel tasks test

* Media indexing worker test

* media tests

* Got all tests working except controller tests

* got all tests working

* Renamed Channel struct to Source

* renamed ChannelTasks

* More renaming; renamed channel details module

* Removed Channel yt-dlp module, instead throwing things in the VideoCollection module

* Renamed what looks like the last of the outstanding data
2024-02-02 17:45:21 -08:00
Kieran
977b69b7c3 Allow subtitle downloading (#11)
* Added subtitle options to media profile model

* Updated media profile form

* Adds subtitle-based options in options builder

* Updates metadata parser to include subtitles

* Adds subtitle_filepaths to media_item

* renamed video_filepath to media_filepath

* Added more fields to media profile show page
2024-01-31 18:55:02 -08:00
Kieran
4dd9d837a3 Download video(s) (first iteration) (#5)
* Updated package.json (and made an excuse to make a branch)

* Video filepath parser (#6)

* Restructured files; Added parser placeholder

* More restructuring

* Added basic parser for hydrating template strings

* Improved docs

* More docs

* Initial implementation of media profiles (#7)

* [WIP] Added basic video download method

* [WIP] Very-WIP first steps at parsing options and downloading

* Made my options safe by default and removed special safe versions

* Ran html generator for mediaprofile model - leaving as-is for now

* Addressed a bunch of TODO comments

* Add "channel" type Media Source (#8)

* [WIP] Working on fetching channel metadata in yt-dlp backend

* Finished first draft of methods to do with querying channels

* Renamed CommandRunnerMock to have a more descriptive name

* Ran the phx generator for the channel model

* Renamed Downloader namespace to MediaClient

* [WIP] saving before attempting LiveView

* LiveView did not work out but here's a working controller how about

* Index a channel (#9)

* Ran a MediaItem generator; Reformatted to my liking

* [WIP] added basic index function

* setup oban

* Added basic Oban job for indexing

* Added in workers for indexing; hooked them into record creation flow

* Added a task model with a phx generator

* Tied together tasks with jobs and channels

* Download indexed videos (#10)

* Clarified documentation

* more comments

* [WIP] hooked up basic video downloading; starting work on metadata

* Added metadata model and parsing

Adding the metadata model made me realize that, in many cases, yt-dlp
returns undesired input in stdout, breaking parsing. In order to get
the metadata model working, I had to change the way in which the app
interacts with yt-dlp. Now, output is written as a file to disk which
is immediately re-read and returned.

* Added tests for video download worker

* Hooked up video downloading to the channel indexing pipeline

* Adds tasks for media items

* Updated video metadata parser to extract the title

* Ran linting
2024-01-30 20:15:59 -08:00
Kieran
44bec0a127 Add CI (#4)
* Added credo

* Added and ran Prettier; First pass at GH Actions

* Updated actions workflow to hopefully work on this branch

* Name the folder correctly how about

* Added proper container prefix to commands

* Apparently you have to get back into the root after commands

* CI is working, update branches to final value
2024-01-19 23:43:25 -08:00
Kieran
89b1640eb6 Initial yt-dlp implementation (#3)
* Added basic runner for yt-dlp commands

* Updated formatting rules

* Added JSON runner; Added test script for CLI interactions

* Reworked yt-dlp runner; added proper test mocks
2024-01-19 22:26:32 -08:00
Kieran
c03fd837ea Initial setup (first pass) (#1)
* Updated Elixir version; made phx interactive

* Added JS formatting rules

* Added yt-dlp to dockerfile

* Added a basic PR template

* Added default responses for the PR template
2024-01-19 17:49:16 -08:00
Kieran Eglin
1455cee3af
Initial commit 🎉 2024-01-18 20:32:01 -08:00