In golf, what is the proper technique when hitting a bunker shot? Assume the bunker is green adjacent.
If the bunker is near the pin, use your sand-wedge.  Also, ensure you properly examined the green, to understand its shape and slope.  Combine this with an understanding of your own skill levels to make a decision on where you wish the ball to land.  For example,  the more skilled you are at these shots, the more precise a location you can identify.  Conversely, the less skilled you are, the less precise you can be in your chosen location, and consequently the more you need to consider a range of potential directions.  In those latter cases, it is best to aim towards the middle of the green rather than the exact placement of the pin.  Once you've made a decision on location, go up to your ball in the bunker.  (Pro-tip: don't forget to bring the rake with you).  Choose an open stance, where your legs are aiming roughly 45 degrees more to the left of the selected landing location.  If you're left-handed, the reverse is true, and your legs are aiming to the right of the intended direction/location.  Dig your shoes roughly an inch into the sand, to get a solid footing.  Next, bring your club face down to the ball, without actually touching the sand (it is not legal to make contact with the sand prior to contact with the ball).  Open the club face so that it aims towards the intended location.  Look one more time at the intended direction, then look down at the ball, and commence your backswing.  The plane of your backswing should be out, inline with the direction of your legs, and roughly three quarters the length of a full swing.  Firmly and confidently accelerate in your downswing, and aim to make contact with the sand roughly half an inch behind the ball.  The sand between the ball and the club head will blunt some of the force from the swing, thereby reducing ball travel distance, while still conveying spin.  A well hit shot can cause the ball to land on the green and immediately stop, possibly even moving back in the direction of the player.  The force in the downswing, combined with the amount of sand caught by the club head, are significant contributors to the amount of backspin on the ball.  Once you're done. rake up your marks as you exit the bunker, leaving no trace that you were ever there.