Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
A
asdf
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Hugo Ishimaru
asdf
Commits
0ba00ac9
Commit
0ba00ac9
authored
11 years ago
by
Francois-Rene Rideau
Browse files
Options
Downloads
Patches
Plain Diff
Add ~/common-lisp/ as a default tree in the registry.
parent
22358808
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
source-registry.lisp
+21
-8
21 additions, 8 deletions
source-registry.lisp
upgrade.lisp
+8
-9
8 additions, 9 deletions
upgrade.lisp
with
29 additions
and
17 deletions
source-registry.lisp
+
21
−
8
View file @
0ba00ac9
...
@@ -16,7 +16,8 @@
...
@@ -16,7 +16,8 @@
#:collect-asds-in-directory
#:collect-sub*directories-asd-files
#:collect-asds-in-directory
#:collect-sub*directories-asd-files
#:validate-source-registry-directive
#:validate-source-registry-form
#:validate-source-registry-directive
#:validate-source-registry-form
#:validate-source-registry-file
#:validate-source-registry-directory
#:validate-source-registry-file
#:validate-source-registry-directory
#:parse-source-registry-string
#:wrapping-source-registry
#:default-source-registry
#:parse-source-registry-string
#:wrapping-source-registry
#:default-user-source-registry
#:default-system-source-registry
#:user-source-registry
#:system-source-registry
#:user-source-registry
#:system-source-registry
#:user-source-registry-directory
#:system-source-registry-directory
#:user-source-registry-directory
#:system-source-registry-directory
#:environment-source-registry
#:process-source-registry
#:environment-source-registry
#:process-source-registry
...
@@ -145,9 +146,11 @@ system names to pathnames of .asd files")
...
@@ -145,9 +146,11 @@ system names to pathnames of .asd files")
'
(
environment-source-registry
'
(
environment-source-registry
user-source-registry
user-source-registry
user-source-registry-directory
user-source-registry-directory
default-user-source-registry
system-source-registry
system-source-registry
system-source-registry-directory
system-source-registry-directory
default-source-registry
))
default-system-source-registry
)
"List of default source registries"
"3.1.0.102"
)
(
defparameter
*source-registry-file*
(
parse-unix-namestring
"source-registry.conf"
))
(
defparameter
*source-registry-file*
(
parse-unix-namestring
"source-registry.conf"
))
(
defparameter
*source-registry-directory*
(
parse-unix-namestring
"source-registry.conf.d/"
))
(
defparameter
*source-registry-directory*
(
parse-unix-namestring
"source-registry.conf.d/"
))
...
@@ -159,17 +162,27 @@ system names to pathnames of .asd files")
...
@@ -159,17 +162,27 @@ system names to pathnames of .asd files")
#+
mkcl
(
:tree
,
(
translate-logical-pathname
"CONTRIB:"
))
#+
mkcl
(
:tree
,
(
translate-logical-pathname
"CONTRIB:"
))
#+
cmu
(
:tree
#p"modules:"
)
#+
cmu
(
:tree
#p"modules:"
)
#+
scl
(
:tree
#p"file://modules/"
)))
#+
scl
(
:tree
#p"file://modules/"
)))
(
defun
default-source-registry
()
(
defun
default-
user-
source-registry
()
`
(
:source-registry
`
(
:source-registry
#+
sbcl
(
:directory
,
(
subpathname
(
user-homedir-pathname
)
".sbcl/systems/"
))
(
:tree
(
:home
"common-lisp/"
))
#+
sbcl
(
:directory
(
:home
".sbcl/systems/"
))
,@
(
loop
:for
dir
:in
,@
(
loop
:for
dir
:in
`
(
,@
(
when
(
os-unix-p
)
`
(
,@
(
when
(
os-unix-p
)
`
(
,
(
or
(
getenv-absolute-directory
"XDG_DATA_HOME"
)
`
(
,
(
or
(
getenv-absolute-directory
"XDG_DATA_HOME"
)
(
subpathname
(
user-homedir-pathname
)
".local/share/"
))
(
subpathname
(
user-homedir-pathname
)
".local/share/"
))))
,@
(
or
(
getenv-absolute-directories
"XDG_DATA_DIRS"
)
'
(
"/usr/local/share"
"/usr/share"
))))
,@
(
when
(
os-windows-p
)
,@
(
when
(
os-windows-p
)
(
mapcar
'get-folder-path
'
(
:local-appdata
:appdata
:common-appdata
))))
(
mapcar
'get-folder-path
'
(
:local-appdata
:appdata
))))
:collect
`
(
:directory
,
(
subpathname*
dir
"common-lisp/systems/"
))
:collect
`
(
:tree
,
(
subpathname*
dir
"common-lisp/source/"
)))
:inherit-configuration
))
(
defun
default-system-source-registry
()
`
(
:source-registry
,@
(
loop
:for
dir
:in
`
(
,@
(
when
(
os-unix-p
)
(
or
(
getenv-absolute-directories
"XDG_DATA_DIRS"
)
'
(
"/usr/local/share"
"/usr/share"
)))
,@
(
when
(
os-windows-p
)
(
list
(
get-folder-path
:common-appdata
))))
:collect
`
(
:directory
,
(
subpathname*
dir
"common-lisp/systems/"
))
:collect
`
(
:directory
,
(
subpathname*
dir
"common-lisp/systems/"
))
:collect
`
(
:tree
,
(
subpathname*
dir
"common-lisp/source/"
)))
:collect
`
(
:tree
,
(
subpathname*
dir
"common-lisp/source/"
)))
:inherit-configuration
))
:inherit-configuration
))
...
...
This diff is collapsed.
Click to expand it.
upgrade.lisp
+
8
−
9
View file @
0ba00ac9
...
@@ -34,15 +34,6 @@ You can compare this string with e.g.: (ASDF:VERSION-SATISFIES (ASDF:ASDF-VERSIO
...
@@ -34,15 +34,6 @@ You can compare this string with e.g.: (ASDF:VERSION-SATISFIES (ASDF:ASDF-VERSIO
(
defvar
*asdf-version*
nil
)
(
defvar
*asdf-version*
nil
)
;; We need to clear systems from versions yet older than the below:
;; We need to clear systems from versions yet older than the below:
(
defparameter
*oldest-forward-compatible-asdf-version*
"2.33"
)
;; 2.32.13 renames a slot in component.
(
defparameter
*oldest-forward-compatible-asdf-version*
"2.33"
)
;; 2.32.13 renames a slot in component.
(
defmacro
defparameter*
(
var
value
&optional
docstring
)
(
let*
((
name
(
string-trim
"*"
var
))
(
valfun
(
intern
(
format
nil
"%~A-~A-~A"
:compute
name
:value
)))
(
clearfun
(
intern
(
format
nil
"%~A-~A"
:clear
name
))))
`
(
progn
(
defun
,
valfun
()
,
value
)
(
defvar
,
var
(
,
valfun
)
,@
(
ensure-list
docstring
))
(
defun
,
clearfun
()
(
setf
,
var
(
,
valfun
)))
(
register-hook-function
'*post-upgrade-cleanup-hook*
',clearfun
))))
(
defvar
*verbose-out*
nil
)
(
defvar
*verbose-out*
nil
)
(
defun
asdf-message
(
format-string
&rest
format-args
)
(
defun
asdf-message
(
format-string
&rest
format-args
)
(
when
*verbose-out*
(
apply
'format
*verbose-out*
format-string
format-args
)))
(
when
*verbose-out*
(
apply
'format
*verbose-out*
format-string
format-args
)))
...
@@ -51,6 +42,14 @@ You can compare this string with e.g.: (ASDF:VERSION-SATISFIES (ASDF:ASDF-VERSIO
...
@@ -51,6 +42,14 @@ You can compare this string with e.g.: (ASDF:VERSION-SATISFIES (ASDF:ASDF-VERSIO
(
defun
upgrading-p
(
&optional
(
oldest-compatible-version
*oldest-forward-compatible-asdf-version*
))
(
defun
upgrading-p
(
&optional
(
oldest-compatible-version
*oldest-forward-compatible-asdf-version*
))
(
and
*previous-asdf-versions*
(
and
*previous-asdf-versions*
(
version<
(
first
*previous-asdf-versions*
)
oldest-compatible-version
)))
(
version<
(
first
*previous-asdf-versions*
)
oldest-compatible-version
)))
(
defmacro
defparameter*
(
var
value
&optional
docstring
(
version
*oldest-forward-compatible-asdf-version*
))
(
let*
((
name
(
string-trim
"*"
var
))
(
valfun
(
intern
(
format
nil
"%~A-~A-~A"
:compute
name
:value
))))
`
(
progn
(
defun
,
valfun
()
,
value
)
(
defvar
,
var
(
,
valfun
)
,@
(
ensure-list
docstring
))
(
when
(
upgrading-p
,
version
)
(
setf
,
var
(
,
valfun
))))))
(
defmacro
when-upgrading
((
&key
(
version
*oldest-forward-compatible-asdf-version*
)
(
defmacro
when-upgrading
((
&key
(
version
*oldest-forward-compatible-asdf-version*
)
(
upgrading-p
`
(
upgrading-p
,
version
))
when
)
&body
body
)
(
upgrading-p
`
(
upgrading-p
,
version
))
when
)
&body
body
)
"A wrapper macro for code that should only be run when upgrading a
"A wrapper macro for code that should only be run when upgrading a
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment