How to find latest version number of a project from sourceforge.net? - sourceforge

My package depends on some binary files from sourceforge.net, I want to automate building steps, how can I find latest version number to download?

I think this API will help You
https://sourceforge.net/p/forge/documentation/Using%20the%20Release%20API/

As Reza commented, you have to parse the output from:
https://sourceforge.net/projects/<projectname>/best_release.json
Example:
curl -qsL "https://sourceforge.net/projects/openofficeorg.mirror/best_release.json" | sed "s/, /,\n/g" | sed -rn "/release/,/\}/{ /filename/{ 0,//s/([^0-9]*)([0-9\.]+)([^0-9]*.*)/\2/ p }}"
Further info:
#260 JSON url for application code to detect when a new release is available.
#747 allow version metadata for each release

Related

Haskell: Could not find module ‘Network.HTTP’

I am trying to write a simple script that takes as input a URL (or set of URLs) and as output it downloads the contents of that page to a file (in particular I am trying to download hundreds of JSON files, which ultimately I wish to diff against other JSON files).
In a file, download.hs, I have import "HTTP" Network.HTTP.
When I run: $ ghc -o download download.hs
I get the following error:
download.hs:24:1: error:
Could not find module ‘Network.HTTP’
Perhaps you meant Network.TLS (needs flag -package-key tls-1.5.2)
|
24 | import "HTTP" Network.HTTP
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
My GHC version is:
$ ghc --version
The Glorious Glasgow Haskell Compilation System, version 8.6.5
I also get errors like:
download.hs:22:1: error:
Could not load module ‘Control.Concurrent.Async’
It is a member of the hidden package ‘async-2.2.2’.
You can run ‘:set -package async’ to expose it.
(Note: this unloads all the modules in the current scope.)
|
22 | import "async" Control.Concurrent.Async (mapConcurrently)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
I think it's possible there have been breaking changes between the ghc versions, and the examples I am finding online to start with may be outdated.
Any pointers on doing started with Haskell, and particularly easy ways to download and diff JSON files in Haskell?
I have been following this example: Running parallel URL downloads in Haskell, this is where I got the code that is erroring now.

Prevent user interaction when adding a package in Solaris

I am trying to install the chef-client package on Solaris 5.10 Sparc.
when i install it with the command pkgadd -d chef.sparc.solaris chef, it asks me "Do you want to continue with the installation of [y,n,?]".
How can i avoid this user interaction and install the package?
Oracle's Help site has documentation for that.
https://docs.oracle.com/cd/E19683-01/817-6958/swmgrpkgs-19113/index.html
And just to back up the link there are 2 ways they list, one with an adiministration file like this placed in the current directory or /var/sadm/install/admin ... it also has an option to pass the path of the administration file directly to pkgadd.
mail=
instance=overwrite
partial=nocheck
runlevel=nocheck
idepend=nocheck
rdepend=nocheck
space=nocheck
setuid=nocheck
conflict=nocheck
action=nocheck
networktimeout=60
networkretries=3
authentication=quit
keystore=/var/sadm/security
proxy=
basedir=default
The other method is to utilize pkgask to store your responses... check the pkgask man page, I figure this is the better way to do it.

New version of OpenSSL causes Plone/Zope to not start

Today's (1 Mar 2016) OpenSSL release has caused the following error when running Plone/Zope
.buildout/eggs/ZODB3-3.10.5-py2.7-linux-x86_64.egg/persistent/cPersistence.so: undefined symbol: SSLv2_method
It's hard to see what's going on since it's a binary file. I also tried updating to ZODB3 3.11.0 which yields the following traceback
.buildout/eggs/ZConfig-2.9.0-py2.7.egg/ZConfig/loader.py", line 217, in schemaComponentSource
package=package)
ZConfig.SchemaResourceError: could not load package ZServer:
.buildout/eggs/zope.security-3.7.4-py2.7-linux-x86_64.egg/zope/security/_proxy.so: undefined symbol: SSLv2_method
Package name: 'ZServer'
File name: 'component.xml'
Package path: None
Is there any workaround for this other than reverting OpenSSL?
zope security is a compiled egg, like all the ones ending with -py2.7-linux-x86_64.egg.
As the traceback says, it cannot find anymore a symbol.
Probably you have to recompile it with the new openssl-dev.
I would try (on a development server first):
backup your compiled egg (mkdir eggs-backup && mv `eggs/zope.security-3.7.4-py2.7-linux-x86_64.egg eggs-backup/)
rerun buildout
This will recompile your missing egg.
Hopefully it works and hopefully it is the only one linked to that library.
Anyway, dependending on the way you patched openssl you may have a lot of other issues (I am thinking about Python, urllib*, curl, wget, ...)
OpenSSL 1.0.2g by default doesn't build with SSLv2 (because of the recent DROWN attack). You may need to manually build it without OPENSSL_NO_SSL2 flag.
(but in fact you shouldn't do this if you're doing some server-related stuff, there is a serious security reason because of which it was disabled, see https://drownattack.com)
I was able to resolve this by upgrading python to 2.7.10+, and then upgrading Pillow and lxml.

R-2.15 on AIX5.3 - rl_readline_name error and configure

I am trying to install R package on AIX5.3. I've two queries regarding it:
I followed Fan Long's steps. I installed the GNU utilities: libiconv and gettext also. However, on running
./configure --with-libpth-prefix=/home/jayant/utils --disable-nls --without-libintl-prefiX --with-included-gettext=home/jayant/utils --with-blas="-llapack -lessl -lblas" --prefix=home/jayant/R-2.15.3
I get the following error:
"sys-std.c", line 893.13: 1506-045 (S) Undeclared identifier rl_readline_name.
Native 'sed' on aix does not support '-e' option. I installed sed from GNU utilities. In the configure script, how should I force it to take my sed instead of the native one. I tried
export sed=/home/jayant/sed-4.2/bin/sed.
but it does'nt work?
You need to ensure that the desired sed gets picked up. Say:
PATH=/home/jayant/sed-4.2/bin:${PATH} ./configure ...
Or if you want to add it to the PATH, say:
PATH=/home/jayant/sed-4.2/bin:${PATH}; export PATH
(Add it to your ${HOME}/.bashrc if you so desire.)

Calling R from within Smalltalk?

Is there any package for calling R from Smalltalk code and accessing return values? Any example script? I'm not looking any particular R functionality, just exploring possibility.
Any Smalltalk flavor would be ok.
In Pharo 4.0 there is a project named RProjectConnector which connects to your locally installed R system.
If you are using Windows first you should copy your R library files evaluating the following script:
| rPath dlls |
(rPath := WinRegistry
queryValue: 'InstallPath'
fromKey: (WinRegistryKey localMachine queryOpenSubkey: 'Software\\R-core\\R')) notNil
ifTrue: [
dlls := (rPath asFileReference / 'bin' / 'i386') entries
select: [ : entry | entry extension = 'dll' ]
thenDo: [ : dllEntry |
dllEntry asFileReference
copyTo: Smalltalk vmDirectory asFileReference / dllEntry basename ] ].
If you are using another not-Ubuntu Linux try to install R 32-bit (it could be a mess).
And finally follow install instructions
I don't know anything, but of course, in all Smalltalk dialects, you have a FFI plugin where you can talk to any external C-based library, like R in this case. mmmmm I guess R is in C...
Check for example:
http://book.pharo-project.org/book/PharoTools/FFI/

Resources