TinyBFG
So I am making a program that sorts out video files in non-video folders and non-video files in video folders and I am done as far as I can tell but I am having issues getting the program over to the client since it uses paths and I have very minimal experience with mac paths. So every time I try to have them test it the tests fail and it is all around the identifies_path_type_and_formats/1 function on line 72. I am new so general help will be appreciated but specifically, I need help getting this to work on mac. I will leave the GitHub link here. You can call it using mix Erovf “type filepath here”
Trending in Questions
I’m working on a project that simulates the bumbl example in the programming phoenix book. It acts almost like an email client. We have a...
New
Hello!
Could someone please give me a help/sample code, how to delete a file from s3 using waffle/waffle_ecto from Phoenix app.
I creat...
New
I’m seeing that a list inside a Kino.DataTable will be interpreted as a charlist, even if the Kino.configure() is set to charlists: :as_l...
New
So my question is quite simple and i have found no conclusive answer on forum, google or AI.
Should we use :erlang.float for Integer to ...
New
Hi, I’ve just set up an application with ash_authentication. There is only magic link strategy for now, so there is no confirmation add o...
New
If a change or preparation module uses Ash.Changeset.get_argument/2 or Ash.Query.get_argument/2 (or any of the other get_argument functio...
New
I’m trying to set up Emacs with elixir-ls via lsp-mode and credo via Flycheck. This should mostly be preconfigured as Flycheck picks up c...
New
Other Trending Topics
I am happy to introduce the very α version of the new programming language compiled to BEAM.
Welcome Cure.
It has literally three kille...
New
Hobbes is a low-level distributed database for the Elixir programming language.
Hobbes provides a simple, safe, and scalable storage lay...
New
Hi there! We created Gust: A task orchestrator inspired by Airflow.
For those who have never heard about Aiflow, it’s a Python-based wor...
New
Beam Bots (or just BB for short) is a framework for building fault-tolerant robotics applications in Elixir using familiar OTP patterns. ...
New
Xamal is a deployment tool for Elixir apps that deploys native releases to bare metal servers over SSH. It’s a port of GitHub - basecamp/...
New
Hello everyone. After busy few months I am happy to announce v0.1.0 of Emerge & Solve.
They are GUI (Emerge) and State management (S...
New
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #library
- #deployment
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #elixirconf
- #channels
- #exunit
- #discussion
- #code-sync
- #podcasts
- #javascript
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #blog-post
- #elixirconf-us
- #elixir-ls
- #ai
- #phoenix_html
- #iex
- #graphql
- #genstage
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #api
- #forms
- #hex
- #security
- #metaprogramming










Showing Posts 1 to 3- Show Best Posts
- Show All (oldest first)
- Show All (newest first)
easco
Macintosh paths are simply Unix paths. There is not really a significant difference between them. So long as the special characters are escaped properly they should behave like unix.
Do you have examples of paths that are problematic?
easco
I suspect the problem in your test is that it is using:
This is an absolute path that starts at the root of the file system. To make it a relative path you could either drop the leading slash
erovf/testor you could add a “.” at the front./erovf/testI suspect that this is a problematic function:
Which looks like it might be creating absolute paths when you don’t mean to.
For example if my cwd is
/Users/easco/Projects/Elixir/erovfthen ask for the base name:and
formats_basenamewill turn this into/erovfwhich is a folder namederovfat the root of the file system and is no longer related to the current working directory.TinyBFG
Sorry for the late response. The client ran the tests on his system and all of the main function related tests failed, so both identifies_misplaced_files/1 tests failed, in turn both of the mix task(run/1) tests failed (because they essentially just run identifies_misplaced_files/1). On top of that all 3 tests for identifies_path_type_and_formats/1 failed, leading to my question about paths and all probably info I should have included in the initial post so I am sorry for that. I turned “/erovf/test” into “erovf/test” and tossed format_basename/1 for just Path.basename/1 and all of my tests are passing so I am pretty happy with this solution so far. I will ask the client to pull it down one more time and run the tests again and once that happens I will return with good news or bad. Do you think that format_relative_path/1 is problematic at all?