luminus-framework / luminus-framework/conman

Split one query definition file into many smaller ones

Open
#51 2 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement help wanted
Dominant language
Clojure
Stars
127
Forks
25
PR merge metrics
No merged PRs in 30d

Description

Is there some built-in functionality that already does that?

I added the following code to my ns:
```
(defmacro rebind-connection []
(cons 'do
(->> (io/file (io/resource "sql"))
(file-seq)
(filter #(.isFile %))
(map #(str "sql/" (.getName %)))
(map #((fn [] `(conman/bind-connection *db* ~%)))))))
```
It works, but feels hackish, because `bind-connection` requires a string as first argument and passing a symbol does not work.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the bind-connection entry point and the rebind-connection macro shown in issue #51, then trace how query definition paths are accepted. Determine whether splitting one query definition into multiple files can be supported without the current macro; done means the supported behavior and its expected input are clear.

Written by the indexing model from the issue text.

Assessment

Tech stack
clojure
Domain
database
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.