# Static content location

**URL:** <https://www.ruby-forum.com/t/static-content-location/107876>\
**Category:** Rails\
**Created:** [June 27, 2007, 1:59am UTC](https://www.ruby-forum.com/t/static-content-location/107876 "2007-06-27T01:59:51Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![giorgio](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/cab0a1/32.png) [@giorgio](https://www.ruby-forum.com/u/giorgio)\
**Post date:** [June 27, 2007, 1:59am UTC](https://www.ruby-forum.com/t/static-content-location/107876/1 "2007-06-27T01:59:51Z")

</div>

I have some staic content (pdf files) that I want to link to.

I have created a /pdfs folder below public and it works fine.

Can I link to a folder somewhere else as every time I update the app I  
have to be careful not to wipe out all the pdfs as all I do is replace  
the whole application directory tree…

Thanks  
G

---

<div class="post-metadata">

**Author:** ![giorgio](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/cab0a1/32.png) [@giorgio](https://www.ruby-forum.com/u/giorgio)\
**Post date:** [June 27, 2007, 2:05am UTC](https://www.ruby-forum.com/t/static-content-location/107876/2 "2007-06-27T02:05:52Z")

</div>

rsync is your friend. Check it out with man rsync.

That is…assuming you’re sane and using some form of UNIX based  
machine. \<\< kidding please don’t flame me 🙂

---

<div class="post-metadata">

**Author:** ![giorgio](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/cab0a1/32.png) [@giorgio](https://www.ruby-forum.com/u/giorgio)\
**Post date:** [June 27, 2007, 2:18am UTC](https://www.ruby-forum.com/t/static-content-location/107876/3 "2007-06-27T02:18:53Z")

</div>

On 2007-06-26, at 20:58 , giorgio wrote:

> Can I link to a folder somewhere else as every time I update the app I  
> have to be careful not to wipe out all the pdfs as all I do is replace  
> the whole application directory tree…

You could just use a symlink:

app in ~/myapp  
pdfs in ~/static/pdfs

ln -s ~/static/pdfs ~/myapp/public/pdfs

You could also start updating your app via svn, set svn:ignore on the  
pdfs dir and be happy.

One assumes you’re on unix, the other assumes you’re using subversion  
(which you can do on windows too).

---

<div class="post-metadata">

**Author:** ![giorgio](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/cab0a1/32.png) [@giorgio](https://www.ruby-forum.com/u/giorgio)\
**Post date:** [June 27, 2007, 4:26am UTC](https://www.ruby-forum.com/t/static-content-location/107876/4 "2007-06-27T04:26:06Z")

</div>

Afraid customers server is Windows…

Not using svn … not sure if that would help… surely svn would be my  
source control repository… what has that got to do with the customers  
server? How would I update their server using svn? I dont even have a  
connection to it!

Maybe I am missing something. When I looked at subversion it was  
remarkably unfriendly… is there a good set of instructions somewhere?

Cheers  
G

---

<div class="post-metadata">

**Author:** ![giorgio](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/cab0a1/32.png) [@giorgio](https://www.ruby-forum.com/u/giorgio)\
**Post date:** [June 27, 2007, 5:00am UTC](https://www.ruby-forum.com/t/static-content-location/107876/5 "2007-06-27T05:00:09Z")

</div>

giorgio wrote:

> 

I find the guide book that comes with TortoiseSVN quite friendly. Just  
search up the TortoiseSVN project - it’s linked from there.  
Hope this helps.

> Cheers  
> G

Cheers,  
Mohit.  
6/27/2007 | 10:58 AM.
