Archive

Posts Tagged ‘mac’

Macports – Your ultimate friend for developers

March 13th, 2012 No comments

Its been long time i last wrote any post here. Today I am going to show you some use of macports.

Macports – One of the best package manager for mac os x. Its specially helpful for advance user like us, who needs to install lots of *nix packages. And also for developers, to maintain their tools, like apache, php, python, ruby, vi, emacs etc etc. So either you are a advance user or developer, u will like this post.

Here we go:

To use macports, the very first thing you will need to install is the gcc compiler and its helping tool. Don’t get afraid, in mac its very simple to get these tools. Just install the Xcode from your 2nd install DVD, if you don’t have the DVD, you can download it from apple site. it’s free 🙂

After the Xcode is installed get the macports installer dmg from macports.org. Mount the dmg and run the installer. it’s damn simple, but you may have to wait 10-20 minutes to complete the installation (based on your mac configuration).

Congratulation!!! your install processing complete. Now how you will use it.

Install package:

$ sudo port install portname

Searching package:

$ port search packagename

Variants:

A very good feature of macports, you can choice what will be configured/installed along with this package. Like if your installing php5 , you may tell the installer to configure it for apache or fastcgi mode or no_web . That’s the best part of macports. You can pick what you need, and what not. Here is the command format:

$ sudo port variants packagename

this command will give you a possible variants list. you will have to +variants_name after the normal ports install command.

$ sudo port install packagename +variants1 +variants2

Upgrade package:

Upgrade is one of the important reason of using package manger, instate of installing everything separately. You will get all your installed packages almost without any effort.

upgrade a single package:

$ sudo port upgrade packagename

this command will upgrade the package along with the pre-selected variants (if any)

upgrade all packages:

$ sudo port upgrade outdated

This command will upgrade all the outdated application/package to the latest version (of-course you will have to sync ports repo, that i described later.)

Port maintenance:

Though most of the task here, you will do very few time in 2-3 months, but still i am showing it here. As we run one single os for years 🙂

Update repository:

To get the latest changes from port repository. The command is very simple:

$ sudo port sync

Remove inactive ports:

One of the good and bad side of macports is, when u upgrading any existing package, it keep the old versions of the package. After few months of use of macports you may feel the need to clean up the space. Here is the single line command to do it.

$ sudo port uninstall inactive

Cleanup ports:

In long run macports store lots of helping files for the compile process. You may like to run this command sometime after 1-2 months to cleanup some space.

$ sudo port clean –all installed

upgrade macports:

Its even simpler to upgrade your installed ports with single command

$ sudo port selfupdate

 

or you can check which ports are outdated by running :

$ sudo port outdated

 

I wrote this post after long time and in very hurry, so there can be some issue or i may missed something. Please let me know, i will fix those.

Make/converting eot from ttf in mac os x & linux

February 7th, 2011 3 comments

As i work with some bangla sites, it’s very common problem for me to create eot of bangla true type font. Today i got a really simple solution. Now (As just learned the system) you can create or convert eot from any ttf font from mac or linux with simple one line command.

$ ttf2eot < fontname.ttf > fontname.eot

That’s all!!!! .

Wait, little work left, you have to install ttf2eot :
in mac os x: sudo port install ttf2eot
linux : download the latest source from http://code.google.com/p/ttf2eot/downloads/list , extract it, then run make in the extracted folder. then you good to go. “./ttf2eot < input.ttf > output.eot”

Set/change default application on mac os x

October 5th, 2010 1 comment

Are you bored with clicking the right click every time to select your fav application to open a file ? At least i am , i like VLC very much and using it for last few years as my media player.

After searching on google i got a very good application to that and plus is it’s free 🙂 , and the site – RCDefaultApp

more data from their site

RCDefaultApp is a Mac OS X 10.2 or higher preference pane that allows a user to set the default application used for various URL schemes, file extensions, file types, MIME types, and Uniform Type Identifiers (or UTIs; MacOS 10.4 only). MacOS X uses the extension and file type settings to choose the application when opening a file in Finder, while Safari and other applications use the URL and MIME type settings at other times for content not related to a file (such as an unknown URL protocol, or a media stream).

RCDefaultApp also allows setting the application when digital cameras or FireWire webcams such as iSight are connected to the computer. For completeness’ sake, there are also settings that mimic the existing “CDs and DVDs” preference pane, which allows setting the action to take when various types of CDs and DVDs are inserted into the computer.

This screenshot shows the section where the default application for various Internet services can be set, similar to the preference in Safari.app and Mail.app.

This shows how to set the application for an extension; just pick the desired application from the list.

This shows the section to set the action for when various types of media are inserted or turned on, similar to the preference in Image Capture.app and iChat.app. The CD and DVD preferences are also duplicated here with easier access to the “Perform action at login” setting.

This shows the section where each application’s possible settings can be seen and assigned at once. The small button in the bottom right is for RCDefaultApp “About” information.

This shows RCDefaultApp as it appears in System Preferences.app.

Download iPhone SDK using wget

August 28th, 2009 8 comments

If you are using slow connection like me and trying to download the apples iPhone SDK , then you already know how much tough it is , because of apple only allow to download this file after login. And non of the download manager can give you the resume facility. so after trying 2 days with different downloaders i tried wget and got sucess 😀

Here i am discribing how to do it. First login to http://developer.apple.com/iphone (if you don’t have any account, just create one, it’s free). then use firefox extension to export (firebug+firecookie) cookie to cookie.txt . Then rest of the task simple. just copy download link from http://developer.apple.com/iphone and give the following command in the console.

$cd /path/to/cookie.txt

$ wget -ct 0 –load-cookies cookie.txt your_file_url

that’s all, now you can resume download without any problem. Here is the command i used to download to download it.

$ wget -ct 0 –server-response –load-cookies cookies.txt http://developer.apple.com/iphone/download.action?path=/iphone/iphone_sdk_3.0__final/iphone_sdk_3.0__leopard__9m2736__final.dmg

If this post help you, don’t forget to share it with others.

Categories: iphone, mac, Tricks Tags: , , ,

started mac-talks.com

July 29th, 2008 1 comment

hi visitors,

everyday i am getting more and more visitor on my technical post. recently i got a new macbook pro, and playing with it. and thinking to sharing my knowledge on mac with all of you. so started mac-talks.com – a dedicated site for mac user/lover. recently i got 3 more guys who joined with me as contributor there. they are salahuddin66, zaher and oshim bhai. if you think you can also join with us, please register your account and send me request to smibrahim[at]gmail.com so that i can add u as author.

anyway let’s go to mac-talks.com 🙂

Categories: mac-talks Tags:
62 queries in 0.125 seconds