- Click Format > Bullets and Numbering... > List Styles
- Select the style you want to modify and click Modify... . You can only modify user-defined styles.
- Update style
- Check Add to template. If you don't check this checkbox, your changes will only be applied to the current document else your changes will be applied to the template and will reflect not only to the current document but also to new documents.
Showing posts with label Tools. Show all posts
Showing posts with label Tools. Show all posts
Tuesday, November 15, 2016
How to modify a user-defined list style in Microsoft Word 2016
How to create a new List Style template in Microsoft Word 2016
- Click Multilevel List icon in Home > Define New Multilevel List... or click Format > Bullets and Numbering... > List Styles > +
- If you want to change the default multilevel style, click the Format on the lower left part of the window and click Numbering...
- To create your own style, you cannot add a new one. You should click Customize.. to modify an existing style. The Reset button is initially disabled/grayed out if the style is not modified/customized (built in style) and becomes enabled after it is modified/customized. When Reset button is enabled, you may click it to reset back to the original built in style.
- Select a style
- If you want your style to appear under Multilevel List icon > List Styles, check Add to Template
Saturday, May 28, 2016
How to update non modifiable Classpath Variables in Eclipse
M2REPO
- Go to Preferences -> Maven -> User Settings
- Update User Settings to the location of your Maven settings.xml. The local repository will be automatically updated based on the localRepository configuration in your settings.xml.
Friday, April 29, 2016
How to call a shell script from another shell script
Note: Make sure to add #!/bin/bash to the first line of the script and make it executable through chmod 700 <path to script>.
- <path to script> or /bin/bash <path to script> or <scriptname> (add script to $PATH environment variable and call as normal command)
- child script is executed in a new shell, changes in child script does not affect parent script
- can be executed asynchronously through background command - <path to script> &
- same as no. 1 but executes child script on background - source <path to script> or . <path to script>
- child script is executed in a current shell
- context is same as parent script (vars and functions of child script becomes visible on parent script)
- exit call in child script will also exit the parent script - exec <path to script>
- terminates the current shell and executes on a new shell
Wednesday, April 27, 2016
How to create Bash Script on Mac
- Create the bash script file.
Sample: File myscript.sh#!/bin/bash #”hash-bang" or “she-bang" indicating that this script is to be interpreted and run by the bash shell echo hello world #prints “hello world”
- Change the file permission to make it an executable. Open the terminal, navigate to the location of the file and type the following command:
chmod 700 myscript.sh
See this link for more info on chmod: http://www.thinkplexx.com/learn/article/unix/command/chmod-permissions-flags-explained-600-0600-700-777-100-etc - Run the script. Type the following in the terminal:
./myscript.sh
Tuesday, April 2, 2013
Merging in SVN using Eclipse
- Do a fresh checkout of the project where you are going to merge into. This is done to ensure that your target branch is up to date.
- Right click the project and click Team -> Merge
- In URL, browse on the source project
- Click Ok
- Resolve any conflicts
Monday, January 28, 2013
Ant buildfile
Each buildfile contains one project and at least one (default) target. Targets contain task elements.
Basic components/tags:
1) project - attributes: name, default, and basedir
2) target - attributes: name, depends, if, unless, descriptiondefault, and basedir
3) tasks - can be built-in or user defined
Common tasks: init, sets properties, prepare, creates directories, build, builds the system, package, creates jar file, install, installs an application to Tomcat or other engine, deploy, deploy a WAR engine, reload, update previously installed application engine, redeploy
4) properties - to reference, enclose in "
Some Built-in Properties: basedir, ant.file, ant.version, ant.project.name, ant.java.version
Tags:
...
Ref:
http://ant.apache.org/manual/using.html
Basic components/tags:
1) project - attributes: name, default, and basedir
2) target - attributes: name, depends, if, unless, descriptiondefault, and basedir
3) tasks - can be built-in or user defined
Common tasks: init, sets properties, prepare, creates directories, build, builds the system, package, creates jar file, install, installs an application to Tomcat or other engine, deploy, deploy a WAR engine, reload, update previously installed application engine, redeploy
4) properties - to reference, enclose in "
${
" and "}
"Some Built-in Properties: basedir, ant.file, ant.version, ant.project.name, ant.java.version
Tags:
Ref:
http://ant.apache.org/manual/using.html
Sunday, January 27, 2013
Windows and Unix common commands
Windows | Unix | Description |
---|---|---|
attrib | change(clear or set) the attribute of the file | |
cd | pwd | print current working directory |
cd <dir> | cd <dir> | change directory |
cls | clear | clear screen |
cmd | Starts a new instance of the Windows command interpreter | |
copy | cp | copy cp /mySrc . |
date, time | date | print current date and/or time |
del | rm | delete |
deltree | rm - r | recursively delete entire directory tree |
dir | ls | list files and directories ls attributes: -a Include hidden fiels (beginning with .) -l long format -s sort by time modified -r reverse sort |
doskey /h | history | print history |
edit | vi etc. | create new file, show edit window common vi commands: /<text> - search forward n - next occurrence ?<text> - search backward n - previous occurrence :set number - show line number :q | :quit | :q! - quit |
exit | exit Ctrl-D | exit |
find | finds files/folders or string in files Ex. dir c:\ /s /b | find "CPU" - display the file names on drive C that contain the string "CPU" find . -name "foo*" | |
find | grep | search grep -n 'UnknownServiceException' */*/*/server.log grep -rni "string" * .* grep -E "a|b" r = recursive i.e, search subdirectories within the current directory n = to print the line numbers to stdout i = case insensitive search .* = hidden files/directory -E = extended regex (i.e., may use | for or) |
help | man | help/manual displays all available commands & how to use them |
ipconfig /all | ipconfig -a | print network details |
mkdir | mkdir | create new folder/directory |
move | mv | move file or folder |
rmdir | rmdir | remove folder/directory |
set | env | set environment variable |
set Path | echo $PATH | print value of environment var PATH |
start | starting/opening a command/program List of commands for Windows XP, Vista and Windows 7: http://ss64.com/nt/run.html Ex. subst notepad start /d "C:\Program Files (x86)\Notepad++" notepad++.exe -> start the executable and close the command prompt that called it | |
subst | substituting path subst R: D:\temp\temp | |
type | cat | display contents of a file, concatenate files or create a new file Ex. cat > 1.txt This is the first line. - creates a simple text file. ^D mrks the end of file. cat 1.txt - display contents of 1.txt cat 1.txt 2.txt > 3.txt - concatenate 1.txt and 2.txt ans save it in 3.txt |
tree | find ., ls -R | print directory structure |
less | display the contents of a text file on console | |
ln | make link Types: 1. Hard link (default) - Points to a file through inode number. If the original file's name is changed, hard link still points to same file. 2. Symbolic link (ln -s) - Points to a file through name. If the original file's name is changed, symbolic link still points to the original name and does not point anymore to the original file. If the original file's content is changed, symbolic link still points to the same file. ln -s myFolder myShortcut - create ln -sfn myFolder2 myShortcut - update -f = force -n = treat LINK_NAME as a normal file if it is a symbolic link to a directory, else LINK_NAME will be treated as symbolic link and will not effectively remove link to previous target and point to new target | |
printenv | print environment variables | |
tar | archive/extract tar -xvf sample.tar.gz |
PATH
Windows | Unix | Description |
---|---|---|
\ | / | Directory separator, e.g. C:\user\docs\sample.txt |
/ | - | Switch, e.g. dir /w |
[drive letter:]\ or \\[server name]\[volume]\ | / | Root directory |
. | . | Current directory |
.. | .. | Parent directory |
~ | Home directory - $HOME var in UNIX, which usually is /home/username | |
C:\user\docs\sample.txt docs\sample.txt A:pic.jpg \\server01\user\docs\sample.txt | //home/user/docs/Letter.txt
. /inthisdir ../../greatgrandparent ~/.rcinfotd> | Sample paths |
Source:
https://en.wikipedia.org/wiki/Path_(computing)
Monday, September 3, 2012
Useful Maven Commands
- mvn --version - displays the Maven version in use
- mvn dependency:tree - displays the dependency tree for this project
- mvn eclipse:eclipse - creates/updates Java eclipse project settings (.project, .classpath, .setting/org.eclipse.jdt.core.prefs, & other config files)
- mvn eclipse:clean - cleans/removes Java eclipse project settings (.project, .classpath, .setting/org.eclipse.jdt.core.prefs, & other config files)
Sunday, May 20, 2012
Wednesday, July 27, 2011
Maven POM
- all POM inherits from Super POM
- if the configuration details are not specified in your POM, Maven will use their defaults(from Super POM)
- to display the final POM (Super POM + your own POM) generated, use command:
mvn help:effective-pom
- hot to skip tests: http://maven.apache.org/plugins/maven-surefire-plugin/examples/skipping-tests.html
Source: http://maven.apache.org/guides/introduction/introduction-to-the-pom.html
Friday, July 22, 2011
Installing your own jar into Local Repository
- Update your maven setting to point the localRepository to where you want to install the jar
- Go to <MAVEN_HOME>\conf directory
- Open settings.xml and change <localRepositorygt; tag to the path where you want to install the jar file
- In command prompt, type:
mvn install:install-file -Dfile=your-artifact-1.0.jar \ [-DpomFile=your-pom.xml] \ [-Dsources=src.jar] \ [-Djavadoc=apidocs.jar] \ [-DgroupId=org.some.group] \ [-DartifactId=your-artifact] \ [-Dversion=1.0] \ [-Dpackaging=jar] \ [-Dclassifier=sources] \ [-DgeneratePom=true] \ [-DcreateChecksum=true] Where: <path-to-file> the path to the file to load <group-id> the group that the file should be registered under <artifact-id> the artifact name for the file <version> the version of the file <packaging> the packaging of the file e.g. jar
Sample:
mvn install:install-file -Dfile=C:\bel\docs\lib\jxl-2.6.3.jar -DgroupId=jexcelapi -DartifactId=jxl -Dversion=2.6.3 -Dpackaging=jar -DgeneratePom -DcreateChecksum=true - In your repository, you will find the new jar installed
- To use the jar, add it in your pom.xml like:
<dependency> <groupId>jexcelapi</groupId> <artifactId>jxl</artifactId> <version>2.6.3</version> </dependency>
Sunday, March 6, 2011
Deployment
- Create the package for full release
- Check out the Project in Eclipse
- Open SVN Repositories. Click Window->Open Perspective->SVN Repository Browser
- Assuming that you already have Repository Location set up, find the project in the trunk or branches
- Right click project then click Show History to ensure that it has the latest change/fix needed
- Tag or make a branch out of the project. Right click project then click New->Tag or Branch
- Right click newly created tag/branch then click Show History to ensure that the it has the latest change/fix needed
- Check out the newly created tag or branch. Right click project the click Check Out
- Build the package
- In the console, go to emea-pom of the checked out project
- Type
mvn clean package –DemeaVersion=${currentversion}
- After a successful build, go to the emea-release project and copy the whole target folder in a different directory.
- Check out the Project in Eclipse
- Generate the config files/folders of the package
- Create a config folder inside the target folder or where the jar is located
- Create folders dev, sit, uat and prod inside config folder
- Open you FTP Client (e.g. FileZilla) and copy the config files to the newly created folders
- DEV
- SIT
- UAT
- PROD
- DEV
- Update the ini file with the changes from project and change the VERSION property
- Create a config folder inside the target folder or where the jar is located
- Deploy DEV using the exploded jar
- In FileZilla, upload/add target/classes/versions to /ams/domains/ACCTSVCS102/versions
- In FileZilla, copy target/config/dev to/ams/domains/ACCTSVCS102/versions/config
- On DEV WEBLOGIC, stop and delete previously deployed ear
- Open Putty and login to DEV (ehdeapp10v.uk.jpmorgan.com)
- Point latest to latest deployed version
- Go to /ams/domains/ACCTSVCS102/versions/biz-rules
- Type rm latest
- Type ln -s {newversionFolder} latest
- Do step 1-3 to config & emea folders as well
- Go to /ams/domains/ACCTSVCS102/versions/biz-rules
- On DEV WEBLOGIC, deploy new ear and start
- Delete temporary files
- Go to /ams/domains/ACCTSVCS102/scripts and type stop_all.sh
- Go to /ams/domains/ACCTSVCS102/servers/admACCTSVCS
- Delete tmp folder. Type rm -rf {folderName}
- Go to /ams/domains/ACCTSVCS102/servers/mngACCTSVCS
- Delete tmp & stage folder
- Go to /ams/domains/ACCTSVCS102/scripts and type start_all.sh
- Go to /ams/domains/ACCTSVCS102/scripts and type stop_all.sh
- Check server: DEV
- In FileZilla, upload/add target/classes/versions to /ams/domains/ACCTSVCS102/versions
- Copy package(jar) and config files to SIT (ehdeapp10v.uk.jpmorgan.com), /home/eis_dev/a_pfdv01/AMSNA
- Create JIRA
- Finish!
Labels:
Apache Maven,
Application Server,
Eclipse,
Operating System,
Technologies,
Tools,
Unix,
Weblogic
Sunday, January 16, 2011
Getting started with Ant
A(nother) N(eat) T(ool)
What is Apache Ant?
http://ant.apache.org/
Download bin:
http://ant.apache.org/bindownload.cgi
What is Apache Ant?
http://ant.apache.org/
Download bin:
http://ant.apache.org/bindownload.cgi
Getting started with Maven
Apache Maven is a software project management and comprehension tool. Based on the concept of a project object model (POM), Maven can manage a project's build, reporting and documentation from a central piece of information.
Download and extract bin from http://maven.apache.org/download.html
Basics:
http://maven.apache.org/guides/getting-started/maven-in-five-minutes.html
To install a package into your local repository:
1) Open <MAVEN_HOME>/conf/settings.xml
2) Set the local repository
<localRepository>S:/bel/repo</localRepository>
3) Set profile
4) Set what profile to activate
5) Set proxy (optional?)
6) Run mvn install (if variables are needed, add -D{varname}={varValue}). To skip test add <skipTests>true</skipTests> on pom.xml (inside properties tag). To set a default/permanent variable, set it in MAVEN_OPTS environment variable
How to set MAVEN_OPTS
-> set MAVEN_OPTS=-Xmx512M -XX:MaxPermSize=128M
-> add in mvn.bat
1) edit <MAVEN_HOME>/bin/mvn.bat
2) add SET MAVEN_OPTS=-Dmaven.test.skip=true
Note:
- dependencies -> mvn install copies all libraries first from WEB-INF/lib to the snapshot lib before downloading all dependencies declared in pom into the snapshot lib. so make sure to always clean up WEB-INF/lib first before executing mvn install to remove any conflicting jars
Source: http://maven.apache.org/
Download and extract bin from http://maven.apache.org/download.html
Basics:
http://maven.apache.org/guides/getting-started/maven-in-five-minutes.html
To install a package into your local repository:
1) Open <MAVEN_HOME>/conf/settings.xml
2) Set the local repository
<localRepository>S:/bel/repo</localRepository>
3) Set profile
4) Set what profile to activate
5) Set proxy (optional?)
6) Run mvn install (if variables are needed, add -D{varname}={varValue}). To skip test add <skipTests>true</skipTests> on pom.xml (inside properties tag). To set a default/permanent variable, set it in MAVEN_OPTS environment variable
How to set MAVEN_OPTS
-> set MAVEN_OPTS=-Xmx512M -XX:MaxPermSize=128M
-> add in mvn.bat
1) edit <MAVEN_HOME>/bin/mvn.bat
2) add SET MAVEN_OPTS=-Dmaven.test.skip=true
Note:
- dependencies -> mvn install copies all libraries first from WEB-INF/lib to the snapshot lib before downloading all dependencies declared in pom into the snapshot lib. so make sure to always clean up WEB-INF/lib first before executing mvn install to remove any conflicting jars
Source: http://maven.apache.org/
Monday, December 6, 2010
Installing Eclipse Plugins
- Copy and Paste
- extract package
- copy the contents of the "features" into the "features" folder of eclipse and copy the contents of the "plugins" into the "plugins" folder of eclipse
- Using Update Manager (existing Eclipse software site)
- click Help->Install New Software...
- select the update site of you eclipse' version from the dropdown folder
- find the feature you want from the list and install
- Using Update Manager (new software site)
- click Help->Install New Software... and click on Available Software tab
- add the download site
- select the update/download site from the dropdown
- find the feature you want from the list and install
Drools - http://download.jboss.org/drools/release/5.5.0.Final/org.drools.updatesite/
Some update sites are dependent on the version of eclipse.
Ex. http://www.jboss.org/tools/download.html
- Using Extension - to separate your plugins from other users
- create an extension folder with eclipse folder, e.g. C:\extension\eclipse
- copy the features and plugins folder of the plugin inside the eclipse folder (for additional plugins, do the Copy and Paste method above)
- open Update Manager and Add Site
- in Add Site window, click Local and specify the location of the extension folder, e.g. C:\extension
- browse and check the plugin you want to install in the Available Software list and click Install
- Using Link
Sunday, December 5, 2010
Tuesday, November 30, 2010
Using FileZilla
- Open FileZilla
- Click File->Site Manager
- Enter host, leave the port blank
Server type: SFTP
Username: SID
Password: orangewins - Click Connect
Wednesday, November 3, 2010
Adding new SVN repository / Check out
SVN must already be installed in your Eclipse before this.
- Open 'SVN Repository Exploring' Perspective. On the 'SVN Repositories' View, click on 'New Repository Location' button.
- Enter URL, username and password, and finish.
- Select the project and right click. Click on 'Find/Check Out As...'
- Choose 'Check out as a project configured using the New Project Wizard' to ensure that the project is check out as an eclipse project (allow setting of build paths)
- Proceed and complete the check out.
Getting started with Eclipse Subversive
Getting started:
http://www.eclipse.org/subversive/documentation/gettingStarted.php
Installation:
http://www.eclipse.org/subversive/documentation/gettingStarted/aboutSubversive/install.php
Sample Installation: (Eclipse Helios)
Install Subversive Plugin using Eclipse update site
1) Help -> Install New Software...
2) In the "Work with" dropdown, select the update site of your eclipse version, e.g Kepler. The available software sites will be listed/displayed.
3) In the list, select Collaboration -> Subversive features then install. At the least, you only need the Subversive SVN Team Provider.
Install Subversive Plugin using SVN update site
1) Help -> Install New Software...
2) In the "Work with" dropdown, select the update site of SVN. If it is not available click "Available Software Sites". On the window that opens, select subversion update locaion. If location is not found, add it. SVN will now appear on the "Work with" dropdown. Select it.
Sample
Name: Subversive
Location: http://download.eclipse.org/technology/subversive/0.7/update-site/
3) In the list, select Subversive features then install.
Install Subversive SVN Connectors
1) Restart Eclipse
2) After restart you'll see connectors discovery dialog.
3) Install Subversive Connectors without registering connectors update site manually.
http://community.polarion.com/projects/subversive/download/eclipse/2.0/helios-site/ -
Update:
If the SVN Connectors are not downloaded,
1. make sure you are using a fresh workspace to launch Subversive Connector Discovery upon restart
2. get the latest release from:
http://www.polarion.com/products/svn/subversive/download.php?utm_source=eclipse.org&utm_medium=link&utm_campaign=subversive
Latest Release – Recommended
Help (free book):
http://svnbook.red-bean.com/
Sources:
http://www.eclipse.org/subversive
http://www.eclipse.org/subversive/documentation/gettingStarted.php
Installation:
http://www.eclipse.org/subversive/documentation/gettingStarted/aboutSubversive/install.php
Sample Installation: (Eclipse Helios)
Install Subversive Plugin using Eclipse update site
1) Help -> Install New Software...
2) In the "Work with" dropdown, select the update site of your eclipse version, e.g Kepler. The available software sites will be listed/displayed.
3) In the list, select Collaboration -> Subversive features then install. At the least, you only need the Subversive SVN Team Provider.
Install Subversive Plugin using SVN update site
1) Help -> Install New Software...
2) In the "Work with" dropdown, select the update site of SVN. If it is not available click "Available Software Sites". On the window that opens, select subversion update locaion. If location is not found, add it. SVN will now appear on the "Work with" dropdown. Select it.
Sample
Name: Subversive
Location: http://download.eclipse.org/technology/subversive/0.7/update-site/
3) In the list, select Subversive features then install.
Install Subversive SVN Connectors
1) Restart Eclipse
2) After restart you'll see connectors discovery dialog.
3) Install Subversive Connectors without registering connectors update site manually.
http://community.polarion.com/projects/subversive/download/eclipse/2.0/helios-site/ -
Update:
If the SVN Connectors are not downloaded,
1. make sure you are using a fresh workspace to launch Subversive Connector Discovery upon restart
2. get the latest release from:
http://www.polarion.com/products/svn/subversive/download.php?utm_source=eclipse.org&utm_medium=link&utm_campaign=subversive
Latest Release – Recommended
- http://download.eclipse.org/technology/subversive/0.7/update-site/ - [required] Subversive plug-in
- http://community.polarion.com/projects/subversive/download/eclipse/2.0/update-site/ - [required] Subversive SVN Connectors
- http://community.polarion.com/projects/subversive/download/integrations/update-site/ - [optional] Subversive Integrations
http://svnbook.red-bean.com/
Sources:
http://www.eclipse.org/subversive
Subscribe to:
Posts (Atom)