Thursday, October 29, 2015

Check if bison is already installed on OpenSUSE

Check if bison is already installed on OpenSUSE:
1. Open terminal.
2. These are the helpful commands:


zypper se bison

which bison

bison --version
or 

bison --help
for help 


For re2c

open terminal
type
which re2c
type:
re2c --version

How to Make Sure if GCC is Installed? [OpenSUSE]

Check if gcc is installed on your Linux device:
1. Open terminal.
2. Type
which gcc
which gives the output:  /usr/bin/gcc

3.  Now, to find the version, type:
gcc -v

good luck! ;)


To install:
 sudo zypper in gcc


or search for gcc (SUSE Linux) 4.8.5
 

Install Sublime Text on Linux [OpenSUSE]

Step 1: Download sublime text folder
Step 2: Unzip the downloaded folder
Step 3: Move the extracted folder to opt directory
Command to move the folder is:
sudo mv Sublime_FOLDER_NAME /opt/

Step 4: Create a symlink in bin:
sudo ln -s /opt/Sublime Text 2/sublime_text /usr//bin/sublime

Now you're all done. You can easily start Sublime Text from the Console by running
sublime

Install F.lux on OpenSUSE (Flux for Linux)

1. Download the flux package from f.lux website.
2. Unzip the folder and copy the xflux file into documents folder.

3. go to the directory where xflux is located. Open terminal and type the following command:
sudo cp xflux /usr/bin/
sudo chmod 755 /usr/bin/xflux
xflux -z 88001    (here 88001 is the zip code for Las Cruces, NM)
4. You'll get the following message:

--------
Welcome to xflux (f.lux for X)
This will only work if you're running X on console.

Sunday, October 18, 2015

How to Create a Bootable USB Flash Drive

Simply follow all of the following steps:
  1. Insert a USB flash drive into a running computer.
  2. Open a Command Prompt window as an administrator.
  3. Type diskpart.
  4. In the new command line window that opens, to determine the USB flash drive number or drive letter, at the command prompt, type list disk, and then click ENTER. Thelist disk command displays all the disks on the computer. Note the drive number or drive letter of the USB flash drive.
  5. At the command prompt, type select disk <X>, where X is the drive number or drive letter of the USB flash drive, and then click ENTER.
  6. Type clean, and the click ENTER. This command deletes all data from the USB flash drive.
  7. To create a new primary partition on the USB flash drive, type create part pri, and then click ENTER.
  8. To select the partition that you just created, type select part 1, and then click ENTER.
  9. To format the partition, type format fs=ntfs quick, and then click ENTER.
    System_CAPS_importantImportant
    If your server platform supports Unified Extensible Firmware Interface (UEFI), you should format the USB flash drive as FAT32 rather than as NTFS. To format the partition as FAT32, type format fs=fat32 quick, and then click ENTER.

  10. Type active, and then click ENTER.
  11. Type exit, and then click ENTER.
  12. When you finish preparing your custom image, save it to the root of the USB flash drive.
Now you're all set. Your pendrive is bootable! :)

(source: https://technet.microsoft.com)

Run Clingo on Windows

there are 2 ways to do this:

1. download clingo and extract it.
2. copy the files into some location. for example: C:\clingo
3. Add "C:\clingo" to the environment variables settings.
4. Then you're all set. Go to command prompt, type cd c:\clingo 
tyen type: clingo 0 someprogram.pl


Second way:
1. download clingo and extract it.
2. copy the files into some location. for example: C:\clingo
3. select clingo folder
4. press Shift key and right click that folder
5. Then you will see the Open Command Prompt Window Here option
click that option and you're all set.

Note: If you're using windows 8 on 32 bit, it may not work the recent version. However, clingo-3.0.5-win32 works perfect.


Happy Grounding and Solving!