stackage-server/templates/stackage-home.hamlet
Michael Snoyman 2b731f15fc Links for inclusive/exclusive Wiki page #3
Pinging @chrisdone
2014-08-25 10:10:22 +03:00

108 lines
4.1 KiB
Plaintext

$newline never
<div .container>
<h1>
#{stackageTitle stackage}
<p>
Published on #{yearMonthDay (stackageUploaded stackage)}
<span .separator>
$if True
<span>
<a href=@{StackageMetadataR ident} title="View metadata on this snapshot, such as package versions">
\Metadata
<span .separator>
<span>
<a href=@{StackageBundleR ident} title="This is useful for making modifications to an existing snapshot">
\Bundle
<p>
<pre>
remote-repo: stackage:@{StackageHomeR ident}
$if isInclusiveOrExclusive
<p>
<a href="https://github.com/fpco/stackage/wiki/Stackage-Server-FAQ#whats-the-difference-between-inclusive-and-exclusive-snapshots">What's the difference between inclusive and exclusive snapshots?</a>
<h3>
Setup guide #
<small>
(click to expand)
<div class="accordion" id="accordion2">
<div class="accordion-group">
<div class="accordion-heading">
<a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion1" href="#collapse1">
<span .number>1
Copy the
<code>remote-repo
line to your Cabal configuration file
<div id="collapse1" class="accordion-body collapse">
<div class="accordion-inner">
<p>
Your #
<code>config
\ file for Cabal should be in your user home directory. For example:
<ul>
<li>Linux: #
<code>
/home/alonzo/.cabal/config
<li>Windows: #
<code>
C:\Users\alonzo\AppData\Roaming\cabal\config
<p>Once you have this open, find the line that says:
<pre>
remote-repo: hackage.haskell.org:http://hackage.haskell.org/packages/archive
<p>
Replace it with the #
<code>remote-repo
\ code sample above.
<div class="accordion-group">
<div class="accordion-heading">
<a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion2" href="#collapse2">
<span .number>2
Remove any existing package config
<div id="collapse2" class="accordion-body collapse">
<div class="accordion-inner">
<p>
If you already have installed some packages from Hackage
\ or elsewhere and you want to start from a fresh package
\ set, you can remove your
<code>ghc/&lt;os&gt;-&lt;ghc-version&gt;
\ directory.
<ul>
<li>
In Linux, the directory is #
<code>~/.ghc
<li>
On Windows the #
<code>.ghc
\ directory, similar to the Cabal
\ configuration, will be under something like: #
<code>
C:\Users\alonzo\AppData\Roaming\ghc
<p>
To clear the GHC 7.2.2. environment, all the
\ user-installed packages, you can remove the directory #
<code>x86_64-linux-7.2.2
.
<em> Be careful
\ that you are sure
\ that you want to clear your package set (re-installing
\ packages takes time!) and that you clear the right one.
<div class="accordion-group">
<div class="accordion-heading">
<a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion3" href="#collapse3">
<span .number>3
Run
<code>
cabal update
<div id="collapse3" class="accordion-body collapse">
<div class="accordion-inner">
<p>
This will download the package index from Stackage and
\ update your local one.
<p>
Now you're ready to install packages!