The best place to *find* answers to programming/development questions, imo, however it's the *worst* place to *ask* questions (if your first question/comment doesn't get any up-rating/response, then u can't ask anymore questions--ridiculously unrealistic), but again, a great reference for *finding* answers.

My Music (Nickleus)

20180913

[SOLVED] jboss-javaee-multi: mvn clean install wildfly:deploy Could not find artifact sun.jdk:jconsole:jar:jdk

I was trying to deploy the wildfly quickstart app "jboss-javaee-multi: Example Using Multiple Java EE 7 Technologies Deployed as an EAR"

in Red Hat Developer Studio (version 12.0.0.GA), following the README instructions:
mvn clean install wildfly:deploy

but it would fail:
[INFO] Reactor Summary:
[INFO]
[INFO] jboss-javaee-multi 0.0.1-SNAPSHOT .................. FAILURE [  3.292 s]
[INFO] jboss-javaee-multi: EJB Module ..................... SKIPPED
[INFO] jboss-javaee-multi: WAR Module ..................... SKIPPED
[INFO] jboss-javaee-multi: EAR Module 0.0.1-SNAPSHOT ...... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 4.755 s
[INFO] Finished at: 2018-09-13T15:16:40+02:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.wildfly.plugins:wildfly-maven-plugin:1.0.2.Final:deploy (default-cli) on project jboss-javaee-multi: Execution default-cli of goal org.wildfly.plugins:wildfly-ma
ven-plugin:1.0.2.Final:deploy failed: Plugin org.wildfly.plugins:wildfly-maven-plugin:1.0.2.Final or one of its dependencies could not be resolved: Could not find artifact sun.jdk:jconsole:jar:jdk
 at specified path C:\Program Files\Java\jdk-10.0.2/../lib/jconsole.jar -> [Help 1]
...
but then I found this thread jconsole not found where James Perkins wrote:
Could you try 1.2.1.Final? That version should work with Java 9.
so to fix my problem i opened the jboss-javaee-multi\pom.xml and changed the value of version.wildfly.maven.plugin from:
<version.wildfly.maven.plugin>1.0.2.Final</version.wildfly.maven.plugin>
to:
<version.wildfly.maven.plugin>1.2.1.Final</version.wildfly.maven.plugin>

then I reran the mvn command in Terminal and it worked:
mvn clean install wildfly:deploy

Thx James :)

20171120

gimp list of basic image editing use cases (UC) [ONGOING]

this will b an ongoing list of basic editing UC in gimp (or image editing, generally):


make selection transparent

select a part of the image to remove and make it see-through


  1. Open your image.
  2. Select the area you want to make transparent. Select the appropriate selection tool from the Tool window or the Tools - Selection Tools menu on the Layer window.
  3. In the Layer window (the one showing your image), select Layer - Transparency - Add Alpha Channel (unless it's greyed out--already done).
  4. Select Edit - Clear.
  5. Save the file.


src: "How to make a transparent background/selection on an image using GIMP"





... to be continued

20170106

[SOLVED] phpstorm project view increase font size

PHPSTORM SETTINGS

Editor > Colors & Fonts
"Save As" for "Scheme" n save a copy of th default scheme, eg "Nick CF (Default copy)"
click "Apply"


Appearance & Behavior > Appearance
check "Override default fonts by (not recommended):"
Name: i selected "Menlo"
Size: 16
click "Apply"

RESTART PHPSTORM.

NOTE: essential comment that helped me solve this.

20160607

[SOLVED] mac osx el capitan: customize menubar clock date & time (hack)

/////////////// SETTING THE OSX MENUBAR DATE & TIME; based on: http://apple.stackexchange.com/a/182435/156582

TERMINAL TAB 1

$ cd

$ nano -w setClock.sh

#!/bin/bash
killall -KILL SystemUIServer
while true
do
        defaults write com.apple.menuextra.clock "DateFormat" "EEEE' 'y.MM.dd' 'HH:mm:ss' 'z' ''week:'' 'ww"
done

$ chmod +x setClock.sh

[START]

$ ./setClock.sh


TERMINAL TAB 2

IF the menubar clock reappears w incorrect desired display format, run:

$ killall -KILL SystemUIServer

repeat (back to [START]) until the clock renders properly. it sometimes takes several attempts.

ELSE, stop the script:


TERMINAL TAB 1

ctrl-c (stop the "while" loop)

///////////////


NOTE about the DateFormat value string:

"EEEE' 'y.MM.dd' 'HH:mm:ss' 'z' ''week:'' 'ww"

spaces seem to need to b surrounded by single quotes ' ', as did week since w was getting interpreted as smth else.

it will render like this:



NOTE 2: this unfortunately doesn't persist thru reboots or logging out (but it does persist if u lock the screen then log back in again), but i don't normally turn off my macbook so.. please tell me if u hav corrections or tips or improvements or new info :)

20160531

[SOLVED] php+jquery page loading twice (2 GET requests) instead of once

i was using jquery to set an element's css background-image inside $(document).ready(function()... , and when i removed that code th page would load once instead of twice:

var url = el.data("imgbg");  // get the url string
el.css("background-image", "url('"+url+"')");  // set bgimg url

what was causing the extra page reload/GET request was an empty url string!

putting a simple if-test on url fixed it:

if (url != "") el.css("background-image", "url('"+url+"')");

:)

my fiddle confirming this behavior:

20160411

jquery how to get this selector as string in event handler/listener

This won't show you the DOM path, but it will output a string representation of what you see in eg chrome debugger, when viewing an object.




    $('.mybtn').click( function(event){
    console.log("%s", this);   // output: "button.mybtn"
    });

https://developer.chrome.com/devtools/docs/console-api#consolelogobject-object

20160322

PHP INCLUDE/REQUIRE PATH SCHEME

a path-include/require-scheme that will work everywhere.
paths can b copied to any file n will work, w/o needing to b changed--
as long as the __ROOT__ variable is properly configured at the top of the file u paste into :)