1
1
Fork 0
mirror of https://github.com/tonydamage/nux-env.git synced 2025-12-11 13:24:28 +01:00

Updated files to use nux/* instead of nux.

This commit is contained in:
Tony Tkáčik 2021-03-24 21:31:40 +01:00
parent f5b7b183d2
commit d30931c3df
9 changed files with 17 additions and 21 deletions

0
.nuxr-app-root Normal file
View file

View file

@ -9,7 +9,9 @@ alias m2-clean-snapshots="find ~/.m2/repository/ -name \"*-SNAPSHOT\" -type d |
# GIT and GITK Aliases
alias gitk-all="(git branch -l) | sed "s/^*//" | xargs gitk"
alias by="mark this"
alias fav="mark multiple fav"
alias mark-this="mark this"
# alias analyse-java-name-conflict="find -iname *.java | grep -v package-info.java | grep -v yang-gen | grep -v target | sed "s/[\\.a-z0-9\\/\\-]*\\/\([\\\$a-zA-Z0-9]*\)\.java/\1/g" | sort | uniq -c | grep -v " 1 ""
# alias analyse-java-annotation=find -iname "*.java" | xargs grep "@$1" | sed "s/@$1\\(.*\\)/\\1/g"

View file

@ -1,11 +1,11 @@
#!/usr/bin/env nux-runner
nux.use nudsl
#nux.use nudsl
## highlight:: <language> <file>
task.highlight() {
nux.use nux/nuxsh
nux.dsl.process highlight nux.nuxsh.language.def "$2"
}
@ -23,7 +23,6 @@ task.plan.compile() {
}
task.plan.preview() {
nux.use nux/nuxsh
nux.dsl.plan nux.nuxsh.language "$2"
plan="$(nudsl.plan.file "$1" "$2")"
if [ -e "$plan" ]; then

View file

@ -4,8 +4,8 @@
#source ~/.config/nux-env/taskie
nux.use nuxfs
nux.use nux.repl
nux.use nux/fs
nux.use nux/repl
nux.use taskie/common
nux.use taskie/backend.github

View file

@ -1,16 +1,11 @@
@namespace nux.repl. {
## nux.repl.start <processor> [<prompt>] [<complete>]
## Starts NUX REPL
##
## FIXME: Add autocompletion
function nux.repl.start {
function .null() {
:
}
local processor=$1;
local prompt=${2:-.null};
local complete=$3;
function :start processor prompt complete {
local command=""
if nux.check.function $complete; then
@ -40,10 +35,7 @@ function nux.repl.start {
## This function is modified version of
## https://github.com/mchav/with/blob/master/with
function nux.repl.completion() {
local prompt=$1;
local compgen_command=$2;
shift;shift;
function :completion prompt compgen_command {
# print readline's prompt for visual separation
if [ "$#" -eq 0 ]; then
echo "$($prompt)$READLINE_LINE"
@ -118,3 +110,5 @@ function nux.repl.completion() {
for completion in "${COMPREPLY[@]}"; do echo "$completion"; done | column
fi
}
}

View file

@ -41,7 +41,7 @@ nux.use nuxr/repl
### Runs an interactive taskie shell with base taskie commands available.
###
function :interactive() {
nux.use nux.repl
nux.use nux/repl
nux.repl.start nuxr.repl.process nuxr.repl.prompt nuxr.repl.completer
}

View file

@ -1,8 +1,9 @@
nux.use nux/fs
nux.log debug "Backend Dir loaded"
backend.dir.detect() {
local dottaskie=$(nuxfs.closest .taskie "$1")
local dottaskiedir=$(nuxfs.closest .taskie.self "$1")
local dottaskie=$(nux.fs.closest .taskie "$1")
local dottaskiedir=$(nux.fs.closest .taskie.self "$1")
if [ -d "$dottaskie" ]; then
echo "$dottaskie"
elif [ -f "$dottaskie" -a "$(yaml r "$dottaskie" backend)" = "dir:self" ]; then

View file

@ -22,7 +22,7 @@ backend.github.with() {
}
backend.github.detect() {
closest_git=$(nuxfs.closest .git "$1")
closest_git=$(nux.fs.closest .git "$1")
git.origins "$closest_git" | grep github.com | while read origin
do

View file

@ -5,7 +5,7 @@ nux.use nux.json
githublike gogs
backend.gogs.detect() {
closest_git=$(nuxfs.closest .git "$1")
closest_git=$(nux.fs.closest .git "$1")
git.origins "$closest_git" | while read origin
do
nux.log debug Testing backend for: $origin