I am receiving the below error when trying to compile Lua in Sublime Text 3.
luajit: cannot open : No such file or directory
[Finished in 0.1s with exit code 1]
[cmd: ['luajit', '']]
[dir: /Applications/Sublime Text.app/Contents/MacOS]
[path: /usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin]
I have tried several packages including the fixMacpaths package trying to fix this. Any ideas?
Edit: Again I have tried most of the solutions on here. This seems to be a file path issue that the mac package is not fixing.
Install Lua, in the Terminal:
curl -R -O http://www.lua.org/ftp/lua-5.3.1.tar.gz
tar zxf lua-5.3.1.tar.gz
cd lua-5.3.1
make macosx test
sudo make install
Create a build system for Lua, in Sublime 3,
goto: Tools > Build System New Build System
and enter a build configuration like the one pasted below
{
"cmd": ["lua", "$file"],
"file_regex": "^(?:(?:\t)|(?:.+: ))(.+):([0-9]+): (.*)$",
"selector": "source.lua"
}
Next, use FixMacPath to help Sublime find your programs.
git clone https://github.com/int3h/SublimeFixMacPath.git ~/Library/Application\ Support/Sublime\ Text\ 3/Packages/FixMacPath
After installing FixMacPath, the user preferences in Sublime will accept additional_path_items.
Next, add addition paths. Open Sublime 3 and go to:
Sublime Text > Preferences > Settings - User and edit the file to add the paths so it can find your Lua files, for example:
{
"additional_path_items" : ["~/Documents"]
}
Next, create a file to test: "~/Documents/hello.lua"
print"Hello, World"
Finally, exit and reopen Sublime, open the test script and build ⌘b.
Tested in Mac OS X 10.10.3, Sublime 3 build 3083, Lua 5.3.1.
Related
I'm trying to create a derivation using nix files, and I'm a little stuck. A package I'm trying to install has a sh file in its repo to build it, and this sh file is running CMake with some arguments.
More specifically, this package is vcpkg.
Here's my vcpkg.nix file:
{ gcc11Stdenv, fetchFromGitHub, ninja, cmake, bash }:
gcc11Stdenv.mkDerivation {
name = "vcpkg-2021.05.12";
src = fetchFromGitHub {
owner = "microsoft";
repo = "vcpkg";
rev = "2021.05.12";
sha256 = "0290fp9nvmbqpgr33rnchn5ngsq4fdll2psvh0bqf0324w2qpsjw";
};
buildPhase = ''
./bootstrap-vcpkg.sh -useSystemBinaries
'';
}
When running it with nix-shell -p 'with (import <nixpkgs> {}); callPackage ./vcpkg.nix {}', I get this error:
configuring
no configure script, doing nothing
building
Could not find cmake. Please install it (and other dependencies) with:
sudo apt-get install cmake ninja-build
error: builder for '/nix/store/riq6vjdhv4z3xvzp8g597xjgwf2rvm03-vcpkg-2021.05.12.drv' failed with exit code 1;
last 9 log lines:
> unpacking sources
> unpacking source archive /nix/store/ycfd6vbgh3s1vy11hfb17b8x33rqj7aw-source
> source root is source
> patching sources
> configuring
> no configure script, doing nothing
> building
> Could not find cmake. Please install it (and other dependencies) with:
> sudo apt-get install cmake ninja-build
For full logs, run 'nix log /nix/store/riq6vjdhv4z3xvzp8g597xjgwf2rvm03-vcpkg-2021.05.12.drv'.
Then, I thought of making cmake and ninja available to buildPhase so the script can use those binaries by adding buildInputs = [cmake ninja];, but I then get this error:
configuring
fixing cmake files...
cmake flags: -DCMAKE_FIND_USE_SYSTEM_PACKAGE_REGISTRY=OFF -DCMAKE_FIND_USE_PACKAGE_REGISTRY=OFF -DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_SKIP_BUILD_RPATH=ON -DBUILD_TESTING=OFF -DCMAKE_INSTALL_LOCALEDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/share/locale -DCMAKE_INSTALL_LIBEXECDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/libexec -DCMAKE_INSTALL_LIBDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/lib -DCMAKE_INSTALL_DOCDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/share/doc/vcpkg -DCMAKE_INSTALL_INFODIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/share/info -DCMAKE_INSTALL_MANDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/share/man -DCMAKE_INSTALL_OLDINCLUDEDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/include -DCMAKE_INSTALL_INCLUDEDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/include -DCMAKE_INSTALL_SBINDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/sbin -DCMAKE_INSTALL_BINDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/bin -DCMAKE_INSTALL_NAME_DIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/lib -DCMAKE_POLICY_DEFAULT_CMP0025=NEW -DCMAKE_OSX_SYSROOT= -DCMAKE_FIND_FRAMEWORK=LAST -DCMAKE_STRIP=/nix/store/854jyvxrvpdpbfn2zaba1v2qgqkxipyh-cctools-binutils-darwin-949.0.1/bin/strip -DCMAKE_RANLIB=/nix/store/854jyvxrvpdpbfn2zaba1v2qgqkxipyh-cctools-binutils-darwin-949.0.1/bin/ranlib -DCMAKE_AR=/nix/store/854jyvxrvpdpbfn2zaba1v2qgqkxipyh-cctools-binutils-darwin-949.0.1/bin/ar -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -DCMAKE_INSTALL_PREFIX=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12
CMake Error: The source directory "/tmp/nix-build-vcpkg-2021.05.12.drv-0/source" does not appear to contain CMakeLists.txt.
Specify --help for usage, or press the help button on the CMake GUI.
error: builder for '/nix/store/76djky7f3xy6ym6v3qlmy941z0bjb8xw-vcpkg-2021.05.12.drv' failed with exit code 1;
last 9 log lines:
> unpacking sources
> unpacking source archive /nix/store/ycfd6vbgh3s1vy11hfb17b8x33rqj7aw-source
> source root is source
> patching sources
> configuring
> fixing cmake files...
> cmake flags: -DCMAKE_FIND_USE_SYSTEM_PACKAGE_REGISTRY=OFF -DCMAKE_FIND_USE_PACKAGE_REGISTRY=OFF -DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_SKIP_BUILD_RPATH=ON -DBUILD_TESTING=OFF -DCMAKE_INSTALL_LOCALEDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/share/locale -DCMAKE_INSTALL_LIBEXECDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/libexec -DCMAKE_INSTALL_LIBDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/lib -DCMAKE_INSTALL_DOCDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/share/doc/vcpkg -DCMAKE_INSTALL_INFODIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/share/info -DCMAKE_INSTALL_MANDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/share/man -DCMAKE_INSTALL_OLDINCLUDEDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/include -DCMAKE_INSTALL_INCLUDEDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/include -DCMAKE_INSTALL_SBINDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/sbin -DCMAKE_INSTALL_BINDIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/bin -DCMAKE_INSTALL_NAME_DIR=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12/lib -DCMAKE_POLICY_DEFAULT_CMP0025=NEW -DCMAKE_OSX_SYSROOT= -DCMAKE_FIND_FRAMEWORK=LAST -DCMAKE_STRIP=/nix/store/854jyvxrvpdpbfn2zaba1v2qgqkxipyh-cctools-binutils-darwin-949.0.1/bin/strip -DCMAKE_RANLIB=/nix/store/854jyvxrvpdpbfn2zaba1v2qgqkxipyh-cctools-binutils-darwin-949.0.1/bin/ranlib -DCMAKE_AR=/nix/store/854jyvxrvpdpbfn2zaba1v2qgqkxipyh-cctools-binutils-darwin-949.0.1/bin/ar -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -DCMAKE_INSTALL_PREFIX=/nix/store/mp38jl4fkv0gqnqhz7a3agx4flwda59n-vcpkg-2021.05.12
> CMake Error: The source directory "/tmp/nix-build-vcpkg-2021.05.12.drv-0/source" does not appear to contain CMakeLists.txt.
> Specify --help for usage, or press the help button on the CMake GUI.
For full logs, run 'nix log /nix/store/76djky7f3xy6ym6v3qlmy941z0bjb8xw-vcpkg-2021.05.12.drv'.
It seems that adding cmake to buildInputs makes nix try to configure the project using cmake, but this is not what I'm trying to do since vcpkg don't simply have a CMakeLists.txt file in its repo.
Adding inherit cmake ninja; didn't seem to help.
You can prevent cmake from changing the configure phase by setting dontUseCmakeConfigure=true in your derivation.
From the nixpkgs manual:
6.7.29. cmake
Overrides the default configure phase to run the CMake command. By default, we use the Make generator of CMake. In addition, dependencies are added automatically to CMAKE_PREFIX_PATH so that packages are correctly detected by CMake. Some additional flags are passed in to give similar behavior to configure-based packages. You can disable this hook’s behavior by setting configurePhase to a custom value, or by setting dontUseCmakeConfigure. cmakeFlags controls flags passed only to CMake. By default, parallel building is enabled as CMake supports parallel building almost everywhere. When Ninja is also in use, CMake will detect that and use the ninja generator.
i am new in react native i want to run react native app in IOS after react-native init, app not run in IOS show some error
Showing All Messages
bash: Native/social_login/socialLogin/node_modules/react-native/scripts/../Libraries: No such file or directory
Command PhaseScriptExecution failed with a nonzero exit code
and build failed please help me
versions
"react": "17.0.1",
"react-native": "0.64.0"
command line tools : Xcode 12.4 (12D4e)
This happened also to me upgrading from 0.63 to 0.64. After trying all solutions I followed a solution moving the folder to a directory where the path contain no spaces and it works and build the app successfully.
Solution to React Native 0.64 build fail
In order for this to work properly follow these steps:
If you previously installed a global react-native-cli package, please
remove it as it may cause unexpected issues (i.e. npm uninstall -g
react-native-cli)
Move the project folder in a path with no spaces (i.e. ~/sub folder
name/ReactNativeApp won't work till you have spaces in the path, so
move in a path like ~/folder/ReactNativeApp)
Then cd into the project folder and upgrade react native to the
latest version with npx react-native upgrade and resolve conflicts if
any
After upgrading remove the node_modules folder and the yarn.lock from
the root and the podfile.lock and Pods folder from ios subfolder
Then cd back to the root and run yarn install && npx pod-install
Now run again your app in Xcode or your IDE and it works
Crazy and absurd that a space in the path-name could cause this issue
This is nothing just an issue with the scheme name for me, in my case my scheme name contains whitespace e.g. "ABC staging", which is not allowed, it got fixed after deleting and creating a new scheme with the name "ABC-staging".
in the case of react-native 0.67^, you may need to apply these changes as well
change line no 7
set -e. ==> set +e
in
node_modules/react-native/scripts/find-node.sh
then use patch-package using the following command :
npx patch-package react-native
this will create a patch file inside the patch folder in root, then you can add in the post-install script in package.json:
"postinstall": "npx patch-package"
This command will run each time a new package is getting added to the project and auto-fix react-native find-node. sh.
Try to run pod install in ios folder
cd ios && pod install
Then when it's done go back to your main folder and run
yarn run ios
If that doesn't work, check out the solutions here
Xcode 10.2.1 Command PhaseScriptExecution failed with a nonzero exit code
There seems to be an issue with coreutils on macOS.
What fixed it for me is:
brew install coreutils
brew install findutils
brew install gnu-sed
Finally change the node_modules/react-native/scripts/generate-specs.sh to:
#!/bin/bash
# Copyright (c) Facebook, Inc. and its affiliates.
#
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
# This script collects the JavaScript spec definitions for core
# native modules and components, then uses react-native-codegen
# to generate native code.
#
# Optionally, set these envvars to override defaults:
# - SRCS_DIR: Path to JavaScript sources
# - CODEGEN_MODULES_LIBRARY_NAME: Defaults to FBReactNativeSpec
# - CODEGEN_MODULES_OUTPUT_DIR: Defaults to React/$CODEGEN_MODULES_LIBRARY_NAME/$CODEGEN_MODULES_LIBRARY_NAME
# - CODEGEN_COMPONENTS_LIBRARY_NAME: Defaults to rncore
# - CODEGEN_COMPONENTS_OUTPUT_DIR: Defaults to ReactCommon/react/renderer/components/$CODEGEN_COMPONENTS_LIBRARY_NAME
#
# Usage:
# ./scripts/generate-specs.sh
# SRCS_DIR=myapp/js CODEGEN_MODULES_LIBRARY_NAME=MySpecs CODEGEN_MODULES_OUTPUT_DIR=myapp/MySpecs ./scripts/generate-specs.sh
#
# shellcheck disable=SC2038
set -e
THIS_DIR=$(cd -P "$(gdirname "$(greadlink "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
TEMP_DIR=$(gmktemp -d /tmp/react-native-codegen-XXXXXXXX)
RN_DIR=$(cd "$THIS_DIR/.." && pwd)
# find node path
source "$RN_DIR/scripts/find-node.sh"
NODE_BINARY="${NODE_BINARY:-$(command -v node || true)}"
USE_FABRIC="${USE_FABRIC:-0}"
cleanup () {
set +e
grm -rf "$TEMP_DIR"
set -e
}
describe () {
printf "\\n\\n>>>>> %s\\n\\n\\n" "$1"
}
main() {
SRCS_DIR=${SRCS_DIR:-$(cd "$RN_DIR/Libraries" && pwd)}
CODEGEN_MODULES_LIBRARY_NAME=${CODEGEN_MODULES_LIBRARY_NAME:-FBReactNativeSpec}
CODEGEN_COMPONENTS_LIBRARY_NAME=${CODEGEN_COMPONENTS_LIBRARY_NAME:-rncore}
CODEGEN_MODULES_OUTPUT_DIR=${CODEGEN_MODULES_OUTPUT_DIR:-"$RN_DIR/React/$CODEGEN_MODULES_LIBRARY_NAME/$CODEGEN_MODULES_LIBRARY_NAME"}
# TODO: $CODEGEN_COMPONENTS_PATH should be programmatically specified, and may change with use_frameworks! support.
CODEGEN_COMPONENTS_PATH="ReactCommon/react/renderer/components"
CODEGEN_COMPONENTS_OUTPUT_DIR=${CODEGEN_COMPONENTS_OUTPUT_DIR:-"$RN_DIR/$CODEGEN_COMPONENTS_PATH/$CODEGEN_COMPONENTS_LIBRARY_NAME"}
TEMP_OUTPUT_DIR="$TEMP_DIR/out"
SCHEMA_FILE="$TEMP_DIR/schema.json"
if [ -z "$NODE_BINARY" ]; then
echo "Error: Could not find node. Make sure it is in bash PATH or set the NODE_BINARY environment variable." 1>&2
exit 1
fi
CODEGEN_PATH=$("$NODE_BINARY" -e "console.log(require('path').dirname(require.resolve('react-native-codegen/package.json')))")
# Special case for running CodeGen from source: build it
if [ ! -d "$CODEGEN_PATH/lib" ]; then
describe "Building react-native-codegen package"
bash "$CODEGEN_PATH/scripts/oss/build.sh"
fi
describe "Generating schema from flow types"
"$NODE_BINARY" "$CODEGEN_PATH/lib/cli/combine/combine-js-to-schema-cli.js" "$SCHEMA_FILE" "$SRCS_DIR"
describe "Generating native code from schema (iOS)"
pushd "$RN_DIR" >/dev/null || exit 1
"$NODE_BINARY" scripts/generate-specs-cli.js ios "$SCHEMA_FILE" "$TEMP_OUTPUT_DIR" "$CODEGEN_MODULES_LIBRARY_NAME"
popd >/dev/null || exit 1
describe "Copying output to final directory"
gmkdir -p "$CODEGEN_COMPONENTS_OUTPUT_DIR" "$CODEGEN_MODULES_OUTPUT_DIR"
gcp -R "$TEMP_OUTPUT_DIR/$CODEGEN_MODULES_LIBRARY_NAME.h" "$TEMP_OUTPUT_DIR/$CODEGEN_MODULES_LIBRARY_NAME-generated.mm" "$CODEGEN_MODULES_OUTPUT_DIR" || exit 1
gfind "$TEMP_OUTPUT_DIR" -type f | gxargs gsed -i.bak "s/$CODEGEN_MODULES_LIBRARY_NAME/$CODEGEN_COMPONENTS_LIBRARY_NAME/g" || exit 1
gfind "$TEMP_OUTPUT_DIR" -type f -not -iname "$CODEGEN_MODULES_LIBRARY_NAME*" -exec cp '{}' "$CODEGEN_COMPONENTS_OUTPUT_DIR/" ';' || exit 1
echo >&2 'Done.'
}
trap cleanup EXIT
main "$#"
notice that some commands are starting with g like greadlink etc.
if your get invalid identifier error in react-native-xcode.sh then under Build Phases -> Bundle React Native code and images it should be: (notice the double quotes):
set -e
export NODE_BINARY="node ../node_modules/react-native/scripts/react-native-xcode.sh"
use patch-package react-native to patch it (if project is being developed on different machines then they must install the brew packages above)
For me it was just having a space in folder name which was in the path of project folder from root.
I had to delete the contents of my ~/.bash_profile file.
I don't even use bash, but some other script populated the file and that broke my build. Deleting the contents fixed the build, immediately. Might not work for you, but thought I'd share.
I'm running Xcode 13.4.1
Installed cocoapods using brew install cocoapods (https://brew.sh/index_es)
M2 apple chip
React Native 0.70
Actually after spending a whole lot of time trying different solutions none of them worked except for Giuseppe's answer. I had white spaces in my path
"/React Native/exampleProject"
1. Renamed folders/files to remove any white space in the path (creating a fresh project within the fixed path worked with no problems at all)
I didn't even had to execute pod install anymore in the ios folder
In my case, i had to export the right path to node
in your terminal type which node, copy the path and export it in ios/xcode.env
export NODE_BINARY="copied node path"
Ok, worth trying this.
(This usually happens if you had multiple imports or any imports missing)
As soon as we get this error message:
Always scroll up & read the issue if written in that log file. Any issues like syntax error or issue related to your js code.
If yes, you can fix that first & re build it.
In my case I had multiple imports of one of the RN components.
Adding $(ARCHS_STANDARD) to Valid Architectures in Build Settings solved it for me
I'm comparatively new to Ubuntu and bitbake. Working my way through 'Bitbake User Manual (https://www.yoctoproject.org/docs/1.6/bitbake-user-manual/bitbake-user-manual.html). Yocto version is sumo (git checkout tags/yocto-2.4.1 -b poky_2.4.1); ubuntu 18.04 version.
Trying to set BBPATH for my project directory (step 3), as:
BBPATH = "/home/benjamin/Documents/c code/helloWorld"
Error:
BBPATH: command not found
All else is working fine, so far. The echo $PATH command shows:
/home/benjamin/digikey/poky/bitbake/bin
/home/benjamin/digikey/poky/bitbake/lib
/home/benjamin/digikey/poky/build/conf
The ./conf directory has the as-yet unedited *.conf files:
local.conf
bblayers.conf
At /home/benjamin, the command:
bitbake --version
returns
BitBake Build Tool Core version 1.38.0
So, that's good. Please give me a hint on setting BBPATH.
You may update your bblayer.conf file as so
BBLAYERS += " ${BSPDIR}/path_to_layer "
you may then use bitbake to compile
eg:
bitbake name-of-recipe
Here are a few references
https://community.nxp.com/docs/DOC-331917
https://www.youtube.com/watch?v=kmrHAHADoI8
Setting up Deep Learning Framework [Lua, Torch]:
I need to set up Lua running with Torch
on Windows 10 and the ZeroBrane IDE, with limited possibilities of installing Software and restricted download rights.
It took me so Long, so I thought I might share a recipe for you guys. I would be glad if it helped you.
SETTING UP
(Admin) Download/Install tdm64/gcc/5.1.0-2.exe Compiler
(Admin) Download/Install ZeroBrane (Lua IDE)
Download lua/5.3.4.tar.gz (https://www.lua.org/download.html)
Write batch file build.cmd
#echo off
setlocal
:: you may change the following variable's value
:: to suit the downloaded version
set lua_version=5.3.4
set work_dir=%~dp0
:: Removes trailing backslash
:: to enhance readability in the following steps
set work_dir=%work_dir:~0,-1%
set lua_install_dir=%work_dir%\lua
set compiler_bin_dir=%work_dir%\tdm-gcc\bin
set lua_build_dir=%work_dir%\lua-%lua_version%
set path=%compiler_bin_dir%;%path%
cd /D %lua_build_dir%
mingw32-make PLAT=mingw
echo.
echo **** COMPILATION TERMINATED ****
echo.
echo **** BUILDING BINARY DISTRIBUTION ****
echo.
:: create a clean "binary" installation
mkdir %lua_install_dir%
mkdir %lua_install_dir%\doc
mkdir %lua_install_dir%\bin
mkdir %lua_install_dir%\include
copy %lua_build_dir%\doc\*.* %lua_install_dir%\doc\*.*
copy %lua_build_dir%\src\*.exe %lua_install_dir%\bin\*.*
copy %lua_build_dir%\src\*.dll %lua_install_dir%\bin\*.*
copy %lua_build_dir%\src\luaconf.h %lua_install_dir%\include\*.*
copy %lua_build_dir%\src\lua.h %lua_install_dir%\include\*.*
copy %lua_build_dir%\src\lualib.h %lua_install_dir%\include\*.*
copy %lua_build_dir%\src\lauxlib.h %lua_install_dir%\include\*.*
copy %lua_build_dir%\src\lua.hpp %lua_install_dir%\include\*.*
echo.
echo **** BINARY DISTRIBUTION BUILT ****
echo.
%lua_install_dir%\bin\lua.exe -e"print [[Hello!]];print[[Simple Lua test successful!!!]]"
echo.
pause
SETTING UP TORCH UNDER LUA ON WINDOWS
--- Quick and dirty ---
Download and unzip the desired binary build from: https://github.com/hiili/WindowsTorch
Generate user.lua file in C:\Users\Name.zbstudio:
path.lua = [[C:\app\tools\torch\bin\luajit.exe]]
Move the C:\app\tools\torch\lua folder to C:\app\tools\torch\bin
--- Untested alternatives ---
Not tested, but I encourage you: https://github.com/torch/torch7/wiki/Windows#cmder
Maybe second best option is to build a virtual environment with linux
Note: More information on Torch can be found here
https://github.com/soumith/cvpr2015/blob/master/cvpr-torch.pdf
GET STARTED WITH LUA AND TORCH
http://torch.ch/docs/tutorials.html
I recommend Torch Video Tutorials to get the basics straight (https://github.com/Atcold/torch-Video-Tutorials)
This is a Torch Cheetsheet for further reading (https://github.com/torch/torch7/wiki/Cheatsheet):
- Newbies
- Installing and Running Torch
- Installing Packages
- Tutorials, Demos by Category
- Loading popular datasets
- List of Packages by Category
I'm working with LaTeX files in Sublime 3 (3059). Given a main .tex file and a .bib file holding the citations, I'd like to be able to issue the standard:
pdflatex main.tex && bibtex main.aux && pdflatex main.tex && pdflatex main.tex
command after hitting a given shortcut in Sublime.
I know there are tools that can do this (LatexTools, LaTeXing) but since what I need is (I believe) so simple, I'd prefer not to depend on extra packages.
How can I store this command and have Sublime run it following a given key combination?
Edit: Based on the answer given, this is the full command I ended up using:
{
"cmd": ["pdflatex $file_name && bibtex $file_base_name.aux && pdflatex $file_name && pdflatex $file_name"],
"shell": true
}
If you want to execute a command you could use Tools > Build System > New Build System to create a file with a content similar to this one:
{
"cmd": ["command"]
}
And then, you should select that as your project Build System. Finally, use ctrl+b to invoke build (invoke your command or script).