From 4798bcac07e01706802ea03886df8a2218f605d4 Mon Sep 17 00:00:00 2001 From: Henrik Volckmer Date: Fri, 18 Aug 2017 13:19:52 -0400 Subject: [PATCH 1/2] auto_registration('/path/to/lib') assumes the last bit to be the top level namespace. --- docs/learn/advanced/explicit-setup/index.html | 8 +++++--- source/learn/advanced/explicit-setup.html.md | 8 +++++--- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/docs/learn/advanced/explicit-setup/index.html b/docs/learn/advanced/explicit-setup/index.html index 50847a1e4..6faf53381 100644 --- a/docs/learn/advanced/explicit-setup/index.html +++ b/docs/learn/advanced/explicit-setup/index.html @@ -61,9 +61,11 @@

Namespaces inferred from directory structure

By default, auto-registration assumes that the directory structure reflects your module/class organization, for example:

# lib/relations/users.rb
-module Relations
-  class Users < ROM::Relation[:sql]
-    schema(infer: true)
+module Lib
+  module Relations
+    class Users < ROM::Relation[:sql]
+      schema(infer: true)
+    end
   end
 end
 
diff --git a/source/learn/advanced/explicit-setup.html.md b/source/learn/advanced/explicit-setup.html.md
index 9794b3b5f..22ee59564 100644
--- a/source/learn/advanced/explicit-setup.html.md
+++ b/source/learn/advanced/explicit-setup.html.md
@@ -69,9 +69,11 @@ organization, for example:
 
 ``` ruby
 # lib/relations/users.rb
-module Relations
-  class Users < ROM::Relation[:sql]
-    schema(infer: true)
+module Lib
+  module Relations
+    class Users < ROM::Relation[:sql]
+      schema(infer: true)
+    end
   end
 end
 

From dff513df7ea2b52f0c1b9603e8cb920dc95bb1c6 Mon Sep 17 00:00:00 2001
From: Henrik Volckmer 
Date: Tue, 19 Sep 2017 10:59:47 -0400
Subject: [PATCH 2/2] oops

---
 source/guides | 0
 source/learn  | 0
 2 files changed, 0 insertions(+), 0 deletions(-)
 mode change 100644 => 120000 source/guides
 mode change 100644 => 120000 source/learn

diff --git a/source/guides b/source/guides
deleted file mode 100644
index b809b4c75..000000000
--- a/source/guides
+++ /dev/null
@@ -1 +0,0 @@
-3.0/guides
\ No newline at end of file
diff --git a/source/guides b/source/guides
new file mode 120000
index 000000000..b809b4c75
--- /dev/null
+++ b/source/guides
@@ -0,0 +1 @@
+3.0/guides
\ No newline at end of file
diff --git a/source/learn b/source/learn
deleted file mode 100644
index 2d8a36bc7..000000000
--- a/source/learn
+++ /dev/null
@@ -1 +0,0 @@
-3.0/learn
\ No newline at end of file
diff --git a/source/learn b/source/learn
new file mode 120000
index 000000000..2d8a36bc7
--- /dev/null
+++ b/source/learn
@@ -0,0 +1 @@
+3.0/learn
\ No newline at end of file