after enabled the c language layer it won't compile - spacevim

I followed the official guide to turned on the C language layer in space vim
but when I compile and run the code by SPC l r it tells me the key binding is not defined
I think this compile and run feature shall be turn on automatically by enable the layer. Is there any way to check the layer(corresponding plugins) are installed correctly

first, make sure lang#c layer is loaded in you configuration file. you can open configuration file via SPC f v d, and Then restart your vim/neovim.
after restart vim, and then open a c file. you can use SPC l r now. please read :h spacevim-layer-lang-c for more info, or checkout the layer page:
http://spacevim.org/layers/lang/c/

Related

Modules of Veins documentation

Does anyone know how to use the make proxy command from the command line in order to see the documentations of the modules? I have installed Instant Veins 5.0 i2 with SimuLTE. It doesn't work generating from the IDE of OMNeT++, it returns an error and the cars simulation can't run, so i need to re-install the whole instant-veins-5.0-i2-simulte.ova file from scratch.
For "Veins LTE 1.3", module documentation can be generated by opening a terminal, changing to the veins/ directory (the one that contains sumo-launchd.py), and running make doxy. Module documentation is then available in doc/doxy/index.html.
Note, however, that Veins LTE has not been in active development for quite some time and integrating much more recent versions of SimuLTE and Veins is now possible via Veins_INET. For more details, see https://veins.car2x.org/documentation/modules/#lte

MPLAB X IDE v 5.40 New project : Unable to set target controller

I downloaded MPLAB X IDE v5.40, while trying to create a standalone-project, i am unable to see the target spec window.
I want to set the target as "PIC16f887".
The next window after i click on Standalone-project is as the below image:
Can anyone help me with this?
Thanks
I don't know if you already work it out, but the same thing happened to me, I contacted Microchip for help, and we sort it out with the following procedure:
1.Close and reopen MPLAB X
2.Try removing the User and cache directories and then re-start the IDE without importing the previous settings
User directory: C:\Users\I14533\AppData\Roaming\mplab_ide\dev\v5.40
Cache directory: C:\Users\I14533\AppData\Local\mplab_ide\Cache\dev\v5.40\var
Uninstall MPLAB X with ALL directories.
Disable Antivirus and Firewalls
Disable the Proxy setting under Tools->Options ->General> disable proxy
Install MPLAB again.
Try creating a sample project and compile your code.
It really worked. It no longer ask for target location. After that I set up Antivirus, Firewall and Proxy again and everything still worked well.

Sigasi in Eclipse

I have just installed the Sigasi Studio pluginin Eclipse (version: Eclipse IDE 2018-12). When I try to launch it,to make a new VHDL file, I get the following:
The selected wizard could not be started. org/eclipse/lsp4j/Range
(occurred in com.sigasi.hdt.vhdl.ui.VhdlExecutableExtensionFactory)
org/eclipse/lsp4j/Range
How I could solve it, please?
Thank you in advance.
Thanks to the Sigasi support, I was able to solve the problem. They wrote me:
The lsp4j plugin version is to recent for the xtext version that ships
with Sigasi Studio 4.2. This issue has been resolved in the preview
channel of release 4.3. Therefore - if you wish to use the plugin
version of Sigasi Studio - I recommend to install the 4.3 preview
following the steps explained on
http://insights.sigasi.com/tech/preview.html.
That's all. Now, I would like to configure Sigasi with GHDL (as a compiler, when I run the project) and GTKWAVE (ad a waves viewer). How can I do that?
Thanks in advance.
SIGASI + GHDL + GTKWAVE (all in one)
It is very powerful combo that you can set up. ATTENTION i use macOS 10.13.6:
Step 1
Make sure you have both installed GHDL and GTKWAVE typing
$ which gtkwave
/usr/local/bin/gtkwave
$ which ghdl
/usr/local/bin/ghdl
Step 2
Open Sigasi an make new Project and create an additional compile.sh file with:
#!/bin/sh
PROJECT_NAME="PWM_Generator"
PROJECT_NAME_TB="PWM_Generator_tb"
WORKING_DIR="/Users/imeksbank/Dropbox/UMHDL"
/usr/local/bin/ghdl -a --workdir=$WORKING_DIR/work.ghdl $WORKING_DIR/$PROJECT_NAME/$PROJECT_NAME.vhd;
/usr/local/bin/ghdl -a --workdir=$WORKING_DIR/work.ghdl $WORKING_DIR/$PROJECT_NAME/$PROJECT_NAME_TB.vhd;
/usr/local/bin/ghdl -e --workdir=$WORKING_DIR/work.ghdl $PROJECT_NAME_TB;
/usr/local/bin/ghdl -r --workdir=$WORKING_DIR/work.ghdl $PROJECT_NAME_TB --vcd=$WORKING_DIR/$PROJECT_NAME/simulation.vcd;
now, be aware, for each project you create your own variables like
PROJECT_NAME
PROJECT_NAME_TB
WORKING_DIR
I use always Dropbox for such approach because then i can access via Windows as well.
And of course, there is a possibility to create custom variables in Sigasi -> External Tool Configurator -> Program -> compile_sh -> environment to pass them to make compile.sh independent. Here you have to deal with it by yourself =)
Step 3 .
Set up you External Tools Configurations to let shell script be executed by Sigasi Studio and create the .vcd file for gtkwave:
Click on currently created Project (in my case it is the PWM_Generator).
After that click on Run -> External Tools -> External Tools Configurations ....
Then go to the left sidebar and under Program create your own anchor like compile_sh.
Finally you have your route :
Program
--compile_sh
And now extend this anchor by a custom created shell script :
Main->Location gets ${workspace_loc:/PWM_Generator/compile.sh}
Main->Working Directory gets ${workspace_loc:/PWM_Generator}
Click Apply and Run and that's it !!! After this you can program VHDL / Verilog and compile via Run -> External Tools -> compile_sh having created .vcd. In your project appears the gtkwave file and there just double click and it starts. =)

What text editors does --dev reload with work

I'm following Odoo's documentation to use the --dev all parameter when I run odoo-bin, in order to have Python models get updated when I change the source code without me having to restart the server. According to the documentation, the reload flag (which is part of all) doesn't work with some text editors. I've been using Sublime Text, and that doesn't seem to work because my model changes don't take effect until I restart the server. Is there a good, commonly used text editor which does work with the reload parameter, or is there a list of text editors which work with it?
If you're running Odoo from the command line via a standard ./odoo-bin --dev reload command then you should not have any issues as long as you have the lib dependencies setup.
Make sure to monitor your log for errors. It requires the watchdog library to be installed via pip install watchdog. Take a look at (currently line 943) of the core files https://github.com/odoo/odoo/blob/10.0/odoo/service/server.py to see how dev reload works:
def start(preload=None, stop=False):
...
watcher = None
if 'reload' in config['dev_mode']:
if watchdog:
watcher = FSWatcher()
watcher.start()
else:
_logger.warning("'watchdog' module not installed. Code autoreload feature is disabled")
if 'werkzeug' in config['dev_mode']:
server.app = DebuggedApplication(server.app, evalex=True)
I am not completely sure, but after doing a quick search on the text editor that I have been primarily using (Atom developed by GitHub), I believe it may have what you're looking for.
Have fun with your future endeavors. I hope my answer helps.
Since odoo uses werkzeug server,you can just use the command line argument to start the server, and everything will be taken care by the server.
./openerp-server --auto-reload
this will restart the server whenever .py file is modified.

How do I install this service_wrapper for mongrel/rails on my windows server?

I have been given the unpleasant task of installing a Rails 3 app I have written on Windows Server 2008 (definitely not my choice - was promised a linux server but I.T. pulled the rug out at the last minute so please don't suggest a change in environment as a solution).
I followed the instructions on this blog post (with a few minor modifications) and now actually have my app up and running under Windows/IIS (proxying mongrel) after a great deal of frustration. The only thing remaining is to get mongrel running as a service.
Unfortunately the mongrel gem has not been kept up-to-date for Rails 3 and while I can get the app running under mongrel at the command line I am unable to use mongrel_service to get the app running as a service.
The solution to this appears to be to use the service_wrapper project on github which has been mentioned in this previous question. The project is not yet complete but apparently functional but comes without documentation/binaries. I have looked through the source-code and don't really understand what is it/how it works so was wondering if someone can point me in the right direction (or, even better, walk me through how) to get this installed.
So close, yet still so far.....
Alright I have this worked out (with a little help from luislavena himself - thanks).
Download service_wrapper-0.1.0-win32.zip from https://github.com/luislavena/service_wrapper/downloads and extract service_wrapper.exe from bin/. I extracted it to C:\service_wrapper.
Next set up a configuration file. I used the hello example and modified it for my app then placed it in the C:\service_wrapper directory.
; Service section, it will be the only section read by service_wrapper
[service]
; Provide full path to executable to avoid issues when executable path was not
; added to system PATH.
executable = C:\Ruby192\bin\ruby.exe
; Provide there the arguments you will pass to executable from the command line
arguments = C:\railsapp\script\rails s -e production
; Which directory will be used when invoking executable.
; Provide a full path to the directory (not to a file)
directory = C:\railsapp
; Optionally specify a logfile where both STDOUT and STDERR of executable will
; be redirected.
; Please note that full path is also required.
logfile = C:\railsapp\log\service_wrapper.log
Now just create the service with
sc create railsapp binPath= "C:\service_wrapper\service_wrapper.exe C:\service_wrapper\service_wrapper.conf" start= auto
(watch for the spaces after binPath= and start=. It won't work without them)
Then start it with
net start railsapp
And you're home and hosed!
I ought to contribute due to this article. For config of using bundle exec, use the following:
Note that I am setting up rubyCAS! it's a great OpenCAS authentication mechanism!!!
; Service section, it will be the only section read by service_wrapper
[service]
; Provide full path to executable to avoid issues when executable path was not
; added to system PATH.
executable = C:\Ruby\bin\ruby.exe
; Provide there the arguments you will pass to executable from the command line
arguments = D:\rubycas-server bundle exec rackup -s mongrel -p 11011
; Which directory will be used when invoking executable.
; Provide a full path to the directory (not to a file)
directory = D:\rubycas-server
; Optionally specify a logfile where both STDOUT and STDERR of executable will
; be redirected.
; Please note that full path is also required.
logfile = D:\rubycas-server\log\service_wrapper.log