Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
4
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Switch to GitLab Next
Sign in / Register
Toggle navigation
V
vitis
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
6
Issues
6
List
Boards
Labels
Service Desk
Milestones
Iterations
Merge Requests
0
Merge Requests
0
Requirements
Requirements
List
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Test Cases
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Package Registry
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issue
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Eugene 'Vindex' Stulin
vitis
Commits
a56e8c81
Commit
a56e8c81
authored
Oct 11, 2019
by
Eugene Stulin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Autocompletion for special categories corrected. Closed
#7
parent
9712d617
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
20 additions
and
5 deletions
+20
-5
build-scripts/compile.sh
build-scripts/compile.sh
+3
-1
build-scripts/env.sh
build-scripts/env.sh
+5
-2
source/_vitis
source/_vitis
+12
-2
No files found.
build-scripts/compile.sh
View file @
a56e8c81
...
...
@@ -3,7 +3,9 @@ source build-scripts/env.sh
SRCDIR
=
source
/
SRC
=
"
${
SRCDIR
}
/*.d"
DEB_HOST_MULTIARCH
=
`
dpkg-architecture
-qDEB_HOST_MULTIARCH
`
if
[[
-e
/usr/bin/dpkg-architecture
]]
;
then
DEB_HOST_MULTIARCH
=
`
dpkg-architecture
-qDEB_HOST_MULTIARCH
`
fi
BINVERSION
=
$1
# release or debug
DC
=
$2
# dmd, ldc2
...
...
build-scripts/env.sh
View file @
a56e8c81
#!/bin/bash
APP
=
vitis
readonly
VERSION
=
`
cat source
/version
`
ARCH
=
`
dpkg
--print-architecture
`
if
[[
-e
/usr/bin/dpkg
]]
;
then
ARCH
=
`
dpkg
--print-architecture
`
fi
readonly
BINPATH_BASEDIR
=
build/bin
BINPATH
=
"
${
BINPATH_BASEDIR
}
/
${
APP
}
"
...
...
@@ -28,4 +31,4 @@ readonly RL_BASHCOMP=${RL_SHAREDIR}/bash-completion/completions
#readonly RPMDIST=${RPMDIST_RAW:1} # not used
readonly
BS
=
build-scripts
readonly
RESOURCES_DIR
=
resources
\ No newline at end of file
readonly
RESOURCES_DIR
=
resources
source/_vitis
View file @
a56e8c81
...
...
@@ -6,7 +6,7 @@ completeSpecificPath() {
# declare variables
local
curr prev words cword
split
local
_item _COMPREPLY
local
method
=
$1
# WithDirs or WithFiles or "" (nothing)
local
method
=
$1
# WithDirs or WithFiles or "" (nothing)
#go the specific directory
pushd
"
${
2
}
"
&>/dev/null
||
return
1
...
...
@@ -36,6 +36,17 @@ completeSpecificPath() {
tempArray[
$i
]=
${
COMPREPLY
[
$i
]
}
done
if
[[
$method
==
WithDirs
]]
;
then
for
_item
in
${
rootAutoDirs
[@]
}
;
do
pushd
"
${
2
}
/
${
_item
}
"
&>/dev/null
||
continue
_init_completion
-s
_filedir
length
=
${#
COMPREPLY
[@]
}
_COMPREPLY+
=
${
COMPREPLY
[0]
}
popd
&>/dev/null
done
fi
# iterate on original replies
for
_item
in
"
${
tempArray
[@]
}
"
;
do
if
[[
$method
==
WithDirs
&&
-d
"
${
_item
}
"
]]
;
then
...
...
@@ -108,7 +119,6 @@ _vitis()
filespaces
=
$(
echo
$str_filespaces
|
tr
";"
"
\n
"
)
fi
COMPREPLY
=()
curr
=
"
${
COMP_WORDS
[COMP_CWORD]
}
"
prev
=
"
${
COMP_WORDS
[COMP_CWORD-1]
}
"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment