I've got a private lib stored on GitHub I'm using on my project.
For some reason the docs for this lib are not loaded in VSCode, so they are not displayed when hovering over the documented method.
In my Cargo.toml the lib is added like this:
[dependencies]
private_lib = { git = "https://github.com/my_account_name/private_lib.git" }
It works so the dependency should be right, do have to do something else, so the docs are loaded as well?
Related
I use Eclipse as IDE for Go (I guess it's called "Goclipse"), developing a web application. All went good and nice until I started to split functionality in smaller packages. Initially I had a package gitserver/user/project/portal. File main.go imported it and everything was working. I suddenly realized, that it should be called gitserver/user/project/webserver instead, and some other files and functionality should go into .../portal. So I did "Rename", by right clicking in Project Explorer.
main.go:
package main
import(
"gitserver/user/project/webserver"
)
func main(){
webserver.DoSomeStuff()
}
Compiler complains that
imported and not used "gitserver/user/project/webserver" as portal
undefined: webserver
[...]
How to untie the "webserver" package from its old name?
GoClipse doesn't actually do any tracking of the old name after the rename is done. Based on what you describe and the error imported and not used "gitserver/user/project/webserver" as portal you probably have an import line along the lines of portal "gitserver/user/project/webserver" somewhere, and probably in the same file it uses webserver.. Double check all your imports because these errors absolutely sound like the rename just got a little mixed up (something that's not uncommon when doing a rename and reusing the old name).
Goclipse may not find every kind of reference to the package when renaming; the change might not be cascaded throughout the project, or even the package files. When you rename a folder, check that the package line has been changed in the package files, and update them if not.
I have a Swift package I would like to make public, however I do not want the source code for all of the files shared.
My solution was to bundle the private source code into a .framework and have the swift package call the private source code.
However I cannot seem to be able to add the .framework into the Swift Package project. Any help?
There is an accepted proposal for binary dependencies in SwiftPM. So when that feature ships you will be able to zip up your framework, if it is an xcframework, and link against it. Until then you can only use unsafe linker flags to do so which means you can’t use the package with Xcode unless it is a local package.
IDE support of ammonite works as described in this post https://blog.jetbrains.com/scala/2018/05/07/ammonite-support/.
Ammonite use private maven repository also works in script as described in the link http://ammonite.io/#import$ivy
the only thing in my situation is how to let intellij find the package in my private maven repository.
intellij looks like won't consult for ~/.ammonite/predef.sc
this is the event message prompt after click the run script.
Import all $ivy dependencies (present in local caches) declared in test.sc
so the question is what is this local caches, it turns out to be the coursier cache ~/.coursier/v1/https/repo1.maven.org/maven2/ and if the package exists there, then when you click the blue import link in the event message, it can resolve it. my not so elegant solution now is sync my local cache to this repository.
the next question is how to add multiple repositories which i don't have much idea yet. (the event is from Scala Library Extension, not sure if it is configurable at all)
Background:
I am in the process of integrating TypeScript into a Play Framework (2.2.6) and I am trying to use mumoshu's plugin to do so. Problem is, the plugin has problems when running "play dist" on a windows machine.
I've forked the code from GitHub in order to make some modifications to the source so I can continue using the plugin.
Question:
I have a play framework plugin in the traditional source structure:
project/build.properties
project/Build.scala
project/plugins.sbt
src/main/scala/TypeScriptPlugin
src/main/scala/TypeScriptKeys.scala
...<other code>
I'd like to include this plugin into another project but I don't really know where to start and how to hookup the settings.
From previous suggestions, I've been able to add the module to my project as follows:
// In project/Build.scala...
object ApplicationBuild extends Build{
lazy val typeScriptModule = ProjectRef(file("../../../play2-typescript"), "play2-typescript")
lazy val main = play.Project(<appName>, <appVersion>, <appDependencies>).settings(typescriptSettings: _*).dependsOn(typeScriptModule).aggregate(typeScriptModule)
}
Where typescriptSettings is defined in the other project... I think, I'm still not 100% sure what typescriptSettings IS other than adding this settings call enabled the plugin to work. This worked fine originally when I had included the plugin in the plugins.sbt file and imported the package com.github.mumoshu.play2.typescript.TypeScriptPlugin._ but now that I'm including the source and explicitly including the module, I can't just import the package... Or at least not the way I used to.
I am still new to scala/sbt and I am having difficulty finding helpful resources online. Any help would be appreciated.
Assuming in the same parent directory you have two directories:
play2-typescript: which is a clone of mumoshu's play2-typescript
play2-typescript-testapp: which is the play app in which you're testing your changes
You need to create, inside play2-typescript-testapp's project directory a file like so:
play2-typescript.sbt
val metaBuild = (project in file(".")
dependsOn ProjectRef(file("../../play2-typescript"), "play2-typescript")
)
Note:
The relative path is to the play2-typescript plugin project, and is relative to the project directory inside play2-typescript-testapp.
Change that to what is correct in your setup, and consider that you can also define it as an absolute path.
There a lots of activator template examples of this. I have a project where we followed the https://typesafe.com/activator/template/play-multidomain-auth path. Specifically, to address your question; the plugins in the root project play-multidomain-auth/project/ are accessible in the modules (play-multidomain-auth/modules/admin/, .../common, and .../web).
This example is the cleanest example I've seen in using multi-project design however that opinion is very subjective.
I hope this helps.
What dependency should be used for clj-sentiment? I have neither found it on the github https://github.com/AndreasKostler/clj-sentiment nor have I been able to locate it within clojars.
The reason I am using this library is to implement the algorithm within https://groups.google.com/forum/#!msg/clojure/7GMuLVvToCE/WmT04KY0_yYJ where the create-cluster function calls to the library for the function get-feature-vec. I searched through all of the branches of this github library for the function get-feature-vec to exclude the need for the dependency. However the search returned empty.
do a git checkout of github project, lein install inside project dir and use library name and version from project.clj
[clj-sentiment "1.0.0-SNAPSHOT"]